Bug 798014 - Remove dead DefineConstructor definition; r=khuey
authorMs2ger <ms2ger@gmail.com>
Sun, 14 Oct 2012 09:39:05 +0200
changeset 110309 919aa3f8deb22fb68bea724f582fe1e36d50ef14
parent 110308 f8c4c106b8064b42d2d1e36bb04e4032bb6fe840
child 110310 5468a80570b24af65ff86851fe0b58846df6084b
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
reviewerskhuey
bugs798014
milestone19.0a1
Bug 798014 - Remove dead DefineConstructor definition; r=khuey
dom/bindings/DOMJSProxyHandler.cpp
--- a/dom/bindings/DOMJSProxyHandler.cpp
+++ b/dom/bindings/DOMJSProxyHandler.cpp
@@ -43,27 +43,16 @@ struct SetListBaseInformation
   SetListBaseInformation() {
     js::SetListBaseInformation((void*) &HandlerFamily, js::JSSLOT_PROXY_EXTRA + JSPROXYSLOT_EXPANDO);
   }
 };
 
 SetListBaseInformation gSetListBaseInformation;
 
 
-bool
-DefineConstructor(JSContext* cx, JSObject* obj, DefineInterface aDefine, nsresult* aResult)
-{
-  bool enabled;
-  bool defined = aDefine(cx, obj, &enabled);
-  MOZ_ASSERT(!defined || enabled,
-             "We defined a constructor but the new bindings are disabled?");
-  *aResult = defined ? NS_OK : NS_ERROR_FAILURE;
-  return enabled;
-}
-
 // static
 JSObject*
 DOMProxyHandler::EnsureExpandoObject(JSContext* cx, JSObject* obj)
 {
   NS_ASSERTION(IsDOMProxy(obj), "expected a DOM proxy object");
   JSObject* expando = GetExpandoObject(obj);
   if (!expando) {
     expando = JS_NewObjectWithGivenProto(cx, nullptr, nullptr,