Remove the const to fix the -Wignored-qualifiers warning with GCC 8

This commit is contained in:
trav90 2018-08-10 15:04:21 -05:00 committed by Roy Tam
commit a52bf9e82b
4 changed files with 5 additions and 5 deletions

View file

@ -75,7 +75,7 @@ template<typename... Ts>
inline bool
ThrowErrorMessage(JSContext* aCx, const ErrNum aErrorNumber, Ts&&... aArgs)
{
binding_detail::ThrowErrorMessage(aCx, static_cast<const unsigned>(aErrorNumber),
binding_detail::ThrowErrorMessage(aCx, static_cast<unsigned>(aErrorNumber),
mozilla::Forward<Ts>(aArgs)...);
return false;
}

View file

@ -32,7 +32,7 @@ struct nsDiskCacheEntry {
mKeySize + mMetaDataSize;
}
char* Key() { return reinterpret_cast<char*const>(this) +
char* Key() { return reinterpret_cast<char*>(this) +
sizeof(nsDiskCacheEntry);
}

View file

@ -372,7 +372,7 @@ template<class EntryType>
PLDHashNumber
nsTHashtable<EntryType>::s_HashKey(const void* aKey)
{
return EntryType::HashKey(static_cast<const KeyTypePointer>(aKey));
return EntryType::HashKey(static_cast<KeyTypePointer>(aKey));
}
template<class EntryType>
@ -381,7 +381,7 @@ nsTHashtable<EntryType>::s_MatchEntry(const PLDHashEntryHdr* aEntry,
const void* aKey)
{
return ((const EntryType*)aEntry)->KeyEquals(
static_cast<const KeyTypePointer>(aKey));
static_cast<KeyTypePointer>(aKey));
}
template<class EntryType>

View file

@ -18,7 +18,7 @@ inline bool IsASCII(char16_t aChar) {
inline const char16_t* aligned(const char16_t* aPtr, const uintptr_t aMask)
{
return reinterpret_cast<const char16_t*>(
reinterpret_cast<const uintptr_t>(aPtr) & ~aMask);
reinterpret_cast<uintptr_t>(aPtr) & ~aMask);
}
/**