mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 871303 - Remove JS_GetGlobalObject from gdb tests. r=sfink
This commit is contained in:
parent
171a9e7ce6
commit
af1abaf13d
@ -1,14 +1,14 @@
|
||||
#include "gdb-tests.h"
|
||||
|
||||
FRAGMENT(JSObject, simple) {
|
||||
JS::Rooted<JSObject *> glob(cx, JS_GetGlobalObject(cx));
|
||||
JS::Rooted<JSObject *> glob(cx, JS_GetGlobalForScopeChain(cx));
|
||||
JS::Rooted<JSObject *> plain(cx, JS_NewObject(cx, 0, 0, 0));
|
||||
JS::Rooted<JSObject *> func(cx, (JSObject *) JS_NewFunction(cx, (JSNative) 1, 0, 0,
|
||||
JS_GetGlobalObject(cx), "dys"));
|
||||
JS_GetGlobalForScopeChain(cx), "dys"));
|
||||
JS::Rooted<JSObject *> anon(cx, (JSObject *) JS_NewFunction(cx, (JSNative) 1, 0, 0,
|
||||
JS_GetGlobalObject(cx), 0));
|
||||
JS_GetGlobalForScopeChain(cx), 0));
|
||||
JS::Rooted<JSFunction *> funcPtr(cx, JS_NewFunction(cx, (JSNative) 1, 0, 0,
|
||||
JS_GetGlobalObject(cx), "formFollows"));
|
||||
JS_GetGlobalForScopeChain(cx), "formFollows"));
|
||||
|
||||
JSObject &plainRef = *plain;
|
||||
JSFunction &funcRef = *funcPtr;
|
||||
|
@ -17,7 +17,7 @@ void callee(JS::Handle<JSObject *> obj, JS::MutableHandle<JSObject *> mutableObj
|
||||
}
|
||||
|
||||
FRAGMENT(Root, handle) {
|
||||
JS::Rooted<JSObject *> global(cx, JS_GetGlobalObject(cx));
|
||||
JS::Rooted<JSObject *> global(cx, JS_GetGlobalForScopeChain(cx));
|
||||
callee(global, &global);
|
||||
(void) global;
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ FRAGMENT(jsid, simple) {
|
||||
JS::Rooted<jsid> string_id(cx, INTERNED_STRING_TO_JSID(cx, interned));
|
||||
jsid int_id = INT_TO_JSID(1729);
|
||||
jsid void_id = JSID_VOID;
|
||||
JS::Rooted<jsid> object_id(cx, OBJECT_TO_JSID(JS_GetGlobalObject(cx)));
|
||||
JS::Rooted<jsid> object_id(cx, OBJECT_TO_JSID(JS_GetGlobalForScopeChain(cx)));
|
||||
|
||||
breakpoint();
|
||||
|
||||
|
@ -15,7 +15,7 @@ FRAGMENT(jsval, simple) {
|
||||
friendly_string.setString(JS_NewStringCopyZ(cx, "Hello!"));
|
||||
|
||||
JS::Rooted<jsval> global(cx);
|
||||
global.setObject(*JS_GetGlobalObject(cx));
|
||||
global.setObject(*JS_GetGlobalForScopeChain(cx));
|
||||
|
||||
// Some interesting value that floating-point won't munge.
|
||||
JS::Rooted<jsval> onehundredthirtysevenonehundredtwentyeighths(cx, DOUBLE_TO_JSVAL(137.0 / 128.0));
|
||||
|
Loading…
Reference in New Issue
Block a user