X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/9dae56ea45a0f5f8136a5c93d6f3a7f99399ca73..14957cd040308e3eeec43d26bae5d76da13fcd85:/runtime/StringObjectThatMasqueradesAsUndefined.h diff --git a/runtime/StringObjectThatMasqueradesAsUndefined.h b/runtime/StringObjectThatMasqueradesAsUndefined.h index 72c0f47..3133944 100644 --- a/runtime/StringObjectThatMasqueradesAsUndefined.h +++ b/runtime/StringObjectThatMasqueradesAsUndefined.h @@ -33,20 +33,22 @@ namespace JSC { static StringObjectThatMasqueradesAsUndefined* create(ExecState* exec, const UString& string) { return new (exec) StringObjectThatMasqueradesAsUndefined(exec, - createStructure(exec->lexicalGlobalObject()->stringPrototype()), string); + createStructure(exec->globalData(), exec->lexicalGlobalObject()->stringPrototype()), string); } private: - StringObjectThatMasqueradesAsUndefined(ExecState* exec, PassRefPtr structure, const UString& string) + StringObjectThatMasqueradesAsUndefined(ExecState* exec, Structure* structure, const UString& string) : StringObject(exec, structure, string) { } - static PassRefPtr createStructure(JSValuePtr proto) + static Structure* createStructure(JSGlobalData& globalData, JSValue proto) { - return Structure::create(proto, TypeInfo(ObjectType, MasqueradesAsUndefined)); + return Structure::create(globalData, proto, TypeInfo(ObjectType, StructureFlags), AnonymousSlotCount, &s_info); } + static const unsigned StructureFlags = OverridesGetOwnPropertySlot | MasqueradesAsUndefined | OverridesGetPropertyNames | StringObject::StructureFlags; + virtual bool toBoolean(ExecState*) const { return false; } };