зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1320408 - Part 22: Remove JSContext* parameter from ProxyObject::renew and Wrapper::Renew. r=jandem
This commit is contained in:
Родитель
cd897b6010
Коммит
33a302accc
|
@ -1033,7 +1033,7 @@ Wrap(JSContext *cx, JS::HandleObject existing, JS::HandleObject obj)
|
|||
}
|
||||
|
||||
if (existing) {
|
||||
js::Wrapper::Renew(cx, existing, obj, wrapper);
|
||||
js::Wrapper::Renew(existing, obj, wrapper);
|
||||
}
|
||||
return js::Wrapper::New(cx, obj, wrapper);
|
||||
}
|
||||
|
|
|
@ -136,7 +136,7 @@ class JS_FRIEND_API(Wrapper) : public BaseProxyHandler
|
|||
static JSObject* New(JSContext* cx, JSObject* obj, const Wrapper* handler,
|
||||
const WrapperOptions& options = WrapperOptions());
|
||||
|
||||
static JSObject* Renew(JSContext* cx, JSObject* existing, JSObject* obj, const Wrapper* handler);
|
||||
static JSObject* Renew(JSObject* existing, JSObject* obj, const Wrapper* handler);
|
||||
|
||||
static const Wrapper* wrapperHandler(JSObject* wrapper);
|
||||
|
||||
|
|
|
@ -722,7 +722,7 @@ js::NewProxyObject(JSContext* cx, const BaseProxyHandler* handler, HandleValue p
|
|||
}
|
||||
|
||||
void
|
||||
ProxyObject::renew(JSContext* cx, const BaseProxyHandler* handler, const Value& priv)
|
||||
ProxyObject::renew(const BaseProxyHandler* handler, const Value& priv)
|
||||
{
|
||||
MOZ_ASSERT(!IsInsideNursery(this));
|
||||
MOZ_ASSERT_IF(IsCrossCompartmentWrapper(this), IsDeadProxyObject(this));
|
||||
|
|
|
@ -312,9 +312,9 @@ Wrapper::New(JSContext* cx, JSObject* obj, const Wrapper* handler,
|
|||
}
|
||||
|
||||
JSObject*
|
||||
Wrapper::Renew(JSContext* cx, JSObject* existing, JSObject* obj, const Wrapper* handler)
|
||||
Wrapper::Renew(JSObject* existing, JSObject* obj, const Wrapper* handler)
|
||||
{
|
||||
existing->as<ProxyObject>().renew(cx, handler, ObjectValue(*obj));
|
||||
existing->as<ProxyObject>().renew(handler, ObjectValue(*obj));
|
||||
return existing;
|
||||
}
|
||||
|
||||
|
|
|
@ -101,7 +101,7 @@ class ProxyObject : public ShapedObject
|
|||
public:
|
||||
static unsigned grayLinkExtraSlot(JSObject* obj);
|
||||
|
||||
void renew(JSContext* cx, const BaseProxyHandler* handler, const Value& priv);
|
||||
void renew(const BaseProxyHandler* handler, const Value& priv);
|
||||
|
||||
static void trace(JSTracer* trc, JSObject* obj);
|
||||
|
||||
|
|
|
@ -564,7 +564,7 @@ WrapperFactory::Rewrap(JSContext* cx, HandleObject existing, HandleObject obj)
|
|||
DEBUG_CheckUnwrapSafety(obj, wrapper, origin, target);
|
||||
|
||||
if (existing)
|
||||
return Wrapper::Renew(cx, existing, obj, wrapper);
|
||||
return Wrapper::Renew(existing, obj, wrapper);
|
||||
|
||||
return Wrapper::New(cx, obj, wrapper);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче