зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1276567 - Fix -Wstring-conversion warnings in js/ directory. r=billm
js/ipc/WrapperAnswer.cpp:531:16 [-Wstring-conversion] implicit conversion turns string literal into bool: 'const char [12]' to 'bool' js/src/jit/MIR.h:63:25 [-Wstring-conversion] implicit conversion turns string literal into bool: 'const char [26]' to 'bool' js/src/jit/SharedIC.cpp:1648:21 [-Wstring-conversion] implicit conversion turns string literal into bool: 'const char [30]' to 'bool' js/src/jsgc.cpp:7135:21 [-Wstring-conversion] implicit conversion turns string literal into bool: 'const char [59]' to 'bool'
This commit is contained in:
Родитель
ed15e4ee96
Коммит
553aca4e35
|
@ -548,7 +548,8 @@ WrapperAnswer::RecvClassName(const ObjectId& objId, nsCString* name)
|
|||
RootedObject obj(cx, findObjectById(cx, objId));
|
||||
if (!obj) {
|
||||
// This is very unfortunate, but we have no choice.
|
||||
return "<dead CPOW>";
|
||||
*name = "<dead CPOW>";
|
||||
return true;
|
||||
}
|
||||
|
||||
LOG("%s.className()", ReceiverObj(objId));
|
||||
|
|
|
@ -60,7 +60,7 @@ MIRType MIRTypeFromValue(const js::Value& vp)
|
|||
case JS_UNINITIALIZED_LEXICAL:
|
||||
return MIRType::MagicUninitializedLexical;
|
||||
default:
|
||||
MOZ_ASSERT(!"Unexpected magic constant");
|
||||
MOZ_ASSERT_UNREACHABLE("Unexpected magic constant");
|
||||
}
|
||||
}
|
||||
return MIRTypeFromValueType(vp.extractNonDoubleType());
|
||||
|
|
|
@ -1645,7 +1645,7 @@ DoCompareFallback(JSContext* cx, void* payload, ICCompare_Fallback* stub_, Handl
|
|||
return false;
|
||||
break;
|
||||
default:
|
||||
MOZ_ASSERT(!"Unhandled baseline compare op");
|
||||
MOZ_ASSERT_UNREACHABLE("Unhandled baseline compare op");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -7122,7 +7122,7 @@ ArenaLists::normalizeBackgroundFinalizeState(AllocKind thingKind)
|
|||
case BFS_DONE:
|
||||
break;
|
||||
default:
|
||||
MOZ_ASSERT(!"Background finalization in progress, but it should not be.");
|
||||
MOZ_ASSERT_UNREACHABLE("Background finalization in progress, but it should not be.");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче