зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1290337 - Part 4: Replace Value parameter to HandleValue in js shell. r=sfink
This commit is contained in:
Родитель
a18c43b831
Коммит
98f4254871
|
@ -2211,10 +2211,8 @@ AssertEq(JSContext* cx, unsigned argc, Value* vp)
|
|||
}
|
||||
|
||||
static JSScript*
|
||||
ValueToScript(JSContext* cx, Value vArg, JSFunction** funp = nullptr)
|
||||
ValueToScript(JSContext* cx, HandleValue v, JSFunction** funp = nullptr)
|
||||
{
|
||||
RootedValue v(cx, vArg);
|
||||
|
||||
if (v.isString()) {
|
||||
// To convert a string to a script, compile it. Parse it as an ES6 Program.
|
||||
RootedLinearString linearStr(cx, StringToLinearString(cx, v.toString()));
|
||||
|
@ -2275,7 +2273,7 @@ GetScriptAndPCArgs(JSContext* cx, unsigned argc, Value* argv, MutableHandleScrip
|
|||
RootedScript script(cx, GetTopScript(cx));
|
||||
*ip = 0;
|
||||
if (argc != 0) {
|
||||
Value v = argv[0];
|
||||
RootedValue v(cx, argv[0]);
|
||||
unsigned intarg = 0;
|
||||
if (v.isObject() &&
|
||||
JS_GetClass(&v.toObject()) == Jsvalify(&JSFunction::class_)) {
|
||||
|
@ -6152,7 +6150,7 @@ DefineConsole(JSContext* cx, HandleObject global)
|
|||
#undef EXTERNAL_FUNCTION_COUNT
|
||||
|
||||
static bool
|
||||
PrintHelpString(JSContext* cx, Value v)
|
||||
PrintHelpString(JSContext* cx, HandleValue v)
|
||||
{
|
||||
JSString* str = v.toString();
|
||||
MOZ_ASSERT(gOutFile->isOpen());
|
||||
|
|
Загрузка…
Ссылка в новой задаче