mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 985695 - Rename JSContext::getLazyType to getSingletonType, because that's the only sense in which it's used. r=terrence
--HG-- extra : rebase_source : db9807b0c311c334ae38409f0dfee259f968b8d3
This commit is contained in:
parent
f8e657144b
commit
ecbe902a2d
@ -367,7 +367,7 @@ class ExclusiveContext : public ThreadSafeContext
|
||||
|
||||
// Zone local methods that can be used freely from an ExclusiveContext.
|
||||
types::TypeObject *getNewType(const Class *clasp, TaggedProto proto, JSFunction *fun = nullptr);
|
||||
types::TypeObject *getLazyType(const Class *clasp, TaggedProto proto);
|
||||
types::TypeObject *getSingletonType(const Class *clasp, TaggedProto proto);
|
||||
inline js::LifoAlloc &typeLifoAlloc();
|
||||
|
||||
// Current global. This is only safe to use within the scope of the
|
||||
|
@ -3923,7 +3923,7 @@ JSCompartment::checkNewTypeObjectTableAfterMovingGC()
|
||||
#endif
|
||||
|
||||
TypeObject *
|
||||
ExclusiveContext::getLazyType(const Class *clasp, TaggedProto proto)
|
||||
ExclusiveContext::getSingletonType(const Class *clasp, TaggedProto proto)
|
||||
{
|
||||
JS_ASSERT_IF(proto.isObject(), compartment() == proto.toObject()->compartment());
|
||||
|
||||
@ -3951,6 +3951,7 @@ ExclusiveContext::getLazyType(const Class *clasp, TaggedProto proto)
|
||||
return nullptr;
|
||||
|
||||
type->initSingleton((JSObject *) TypeObject::LAZY_SINGLETON);
|
||||
MOZ_ASSERT(type->singleton(), "created type must be a proper singleton");
|
||||
|
||||
return type;
|
||||
}
|
||||
|
@ -376,7 +376,7 @@ JSObject::setSingletonType(js::ExclusiveContext *cx, js::HandleObject obj)
|
||||
JS_ASSERT_IF(cx->isJSContext(),
|
||||
!IsInsideNursery(cx->asJSContext()->runtime(), obj.get()));
|
||||
|
||||
js::types::TypeObject *type = cx->getLazyType(obj->getClass(), obj->getTaggedProto());
|
||||
js::types::TypeObject *type = cx->getSingletonType(obj->getClass(), obj->getTaggedProto());
|
||||
if (!type)
|
||||
return false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user