зеркало из https://github.com/mozilla/gecko-dev.git
Bug 934485 - Remove unused ProxyOptions::forceForegroundFinalization() r=terrence
This commit is contained in:
Родитель
3219a5619c
Коммит
2cb2badc60
|
@ -357,8 +357,7 @@ SetProxyExtra(JSObject *obj, size_t n, const Value &extra)
|
|||
class MOZ_STACK_CLASS ProxyOptions {
|
||||
public:
|
||||
ProxyOptions() : callable_(false),
|
||||
singleton_(false),
|
||||
forceForegroundFinalization_(false)
|
||||
singleton_(false)
|
||||
{}
|
||||
|
||||
bool callable() const { return callable_; }
|
||||
|
@ -373,18 +372,9 @@ class MOZ_STACK_CLASS ProxyOptions {
|
|||
return *this;
|
||||
}
|
||||
|
||||
bool forceForegroundFinalization() const {
|
||||
return forceForegroundFinalization_;
|
||||
}
|
||||
ProxyOptions &setForceForegroundFinalization(bool flag) {
|
||||
forceForegroundFinalization_ = true;
|
||||
return *this;
|
||||
}
|
||||
|
||||
private:
|
||||
bool callable_;
|
||||
bool singleton_;
|
||||
bool forceForegroundFinalization_;
|
||||
};
|
||||
|
||||
JS_FRIEND_API(JSObject *)
|
||||
|
|
|
@ -43,7 +43,7 @@ ProxyObject::New(JSContext *cx, BaseProxyHandler *handler, HandleValue priv, Tag
|
|||
NewObjectKind newKind =
|
||||
(clasp == &OuterWindowProxyObject::class_ || options.singleton()) ? SingletonObject : GenericObject;
|
||||
gc::AllocKind allocKind = gc::GetGCObjectKind(clasp);
|
||||
if (!options.forceForegroundFinalization() && handler->finalizeInBackground(priv))
|
||||
if (handler->finalizeInBackground(priv))
|
||||
allocKind = GetBackgroundAllocKind(allocKind);
|
||||
RootedObject obj(cx, NewObjectWithGivenProto(cx, clasp, proto, parent, allocKind, newKind));
|
||||
if (!obj)
|
||||
|
|
Загрузка…
Ссылка в новой задаче