aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bindings/codegen/CodegenRust.py
diff options
context:
space:
mode:
authorNathan Froyd <froydnj@gmail.com>2015-10-27 14:14:11 -0400
committerNathan Froyd <froydnj@gmail.com>2015-10-27 18:08:35 -0400
commitc82b6ce8431e1379b7bd4689c2aadadbdc65c8b7 (patch)
tree48d55373d6d3952898b29c63937cab200676e437 /components/script/dom/bindings/codegen/CodegenRust.py
parent3d39646c8e89c304cbae0c2490f2b82e47ccb7c5 (diff)
downloadservo-c82b6ce8431e1379b7bd4689c2aadadbdc65c8b7.tar.gz
servo-c82b6ce8431e1379b7bd4689c2aadadbdc65c8b7.zip
move reserved slot setting for DOM globals
Moving this slot setting prior to initializing standard classes and other initialization tasks means that we can effectively use JS_GC_ZEAL. Fixes #6057.
Diffstat (limited to 'components/script/dom/bindings/codegen/CodegenRust.py')
-rw-r--r--components/script/dom/bindings/codegen/CodegenRust.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/components/script/dom/bindings/codegen/CodegenRust.py b/components/script/dom/bindings/codegen/CodegenRust.py
index fab487215d7..36921feafe7 100644
--- a/components/script/dom/bindings/codegen/CodegenRust.py
+++ b/components/script/dom/bindings/codegen/CodegenRust.py
@@ -2163,12 +2163,10 @@ let obj = RootedObject::new(cx, obj);\
" create_dom_global(\n"
" cx,\n"
" &Class.base as *const js::jsapi::Class as *const JSClass,\n"
+ " raw as *const libc::c_void,\n"
" Some(%s))\n"
");\n"
- "assert!(!obj.ptr.is_null());\n"
- "\n"
- "JS_SetReservedSlot(obj.ptr, DOM_OBJECT_SLOT,\n"
- " PrivateValue(raw as *const libc::c_void));" % TRACE_HOOK_NAME)
+ "assert!(!obj.ptr.is_null());" % TRACE_HOOK_NAME)
else:
create += ("let obj = {\n"
" let _ac = JSAutoCompartment::new(cx, proto.ptr);\n"