Bug 865969 part 5. Root the id argument of WebIDL DefineInterface methods. r=smaug
authorBoris Zbarsky <bzbarsky@mit.edu>
Fri, 03 May 2013 19:29:08 -0400
changeset 141758 f7dbbff05f4890493d8ad2f5075147e49687b18f
parent 141757 f088bdf15d4e53913e61af2fb7acaff8c54e75ab
child 141759 35c6ad8bb2e4aeac66cb6c80eac2216b96fbc43f
push id2579
push userakeybl@mozilla.com
push dateMon, 24 Jun 2013 18:52:47 +0000
treeherdermozilla-beta@b69b7de8a05a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug
bugs865969
milestone23.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 865969 part 5. Root the id argument of WebIDL DefineInterface methods. r=smaug
dom/base/nsDOMClassInfo.cpp
dom/base/nsDOMClassInfo.h
dom/bindings/Codegen.py
js/xpconnect/src/xpcpublic.h
--- a/dom/base/nsDOMClassInfo.cpp
+++ b/dom/base/nsDOMClassInfo.cpp
@@ -4400,17 +4400,17 @@ ConstructorEnabled(const nsGlobalNameStr
   }
 
   return true;
 }
 
 // static
 nsresult
 nsWindowSH::GlobalResolve(nsGlobalWindow *aWin, JSContext *cx,
-                          JSObject *obj, jsid id, bool *did_resolve)
+                          JSObject *obj, JS::Handle<jsid> id, bool *did_resolve)
 {
   *did_resolve = false;
 
   nsScriptNameSpaceManager *nameSpaceManager =
     nsJSRuntime::GetNameSpaceManager();
   NS_ENSURE_TRUE(nameSpaceManager, NS_ERROR_NOT_INITIALIZED);
 
   nsDependentJSString name(id);
--- a/dom/base/nsDOMClassInfo.h
+++ b/dom/base/nsDOMClassInfo.h
@@ -333,17 +333,18 @@ protected:
   {
   }
 
   virtual ~nsWindowSH()
   {
   }
 
   static nsresult GlobalResolve(nsGlobalWindow *aWin, JSContext *cx,
-                                JSObject *obj, jsid id, bool *did_resolve);
+                                JSObject *obj, JS::Handle<jsid> id,
+                                bool *did_resolve);
 
 public:
   NS_IMETHOD PreCreate(nsISupports *nativeObj, JSContext *cx,
                        JSObject *globalObj, JSObject **parentObj);
 #ifdef DEBUG
   NS_IMETHOD PostCreate(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
                         JSObject *obj)
   {
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -1912,17 +1912,18 @@ class CGGetConstructorObjectMethod(CGGet
 class CGDefineDOMInterfaceMethod(CGAbstractMethod):
     """
     A method for resolve hooks to try to lazily define the interface object for
     a given interface.
     """
     def __init__(self, descriptor):
         args = [Argument('JSContext*', 'aCx'),
                 Argument('JS::Handle<JSObject*>', 'aGlobal'),
-                Argument('jsid', 'id'), Argument('bool*', 'aEnabled')]
+                Argument('JS::Handle<jsid>', 'id'),
+                Argument('bool*', 'aEnabled')]
         CGAbstractMethod.__init__(self, descriptor, 'DefineDOMInterface', 'JSObject*', args)
 
     def declare(self):
         if self.descriptor.workers:
             return ''
         return CGAbstractMethod.declare(self)
 
     def define(self):
--- a/js/xpconnect/src/xpcpublic.h
+++ b/js/xpconnect/src/xpcpublic.h
@@ -491,18 +491,18 @@ inline bool IsDOMProxy(JSObject *obj, co
 }
 
 inline bool IsDOMProxy(JSObject *obj)
 {
     return IsDOMProxy(obj, js::GetObjectClass(obj));
 }
 
 typedef JSObject*
-(*DefineInterface)(JSContext *cx, JS::Handle<JSObject*> global, jsid id,
-                   bool *enabled);
+(*DefineInterface)(JSContext *cx, JS::Handle<JSObject*> global,
+                   JS::Handle<jsid> id, bool *enabled);
 
 typedef JSObject*
 (*ConstructNavigatorProperty)(JSContext *cx, JS::Handle<JSObject*> naviObj);
 
 typedef bool
 (*PrefEnabled)();
 
 extern bool