-
barraclough@apple.com authored
https://bugs.webkit.org/show_bug.cgi?id=69478 Reviewed by Darin Adler. JSC supports a split global object, as used by WebCore for the Window. As a stage of making this visible to JSC, make it so that if the global this value is not the global object itself, it must be a subclass of JSGlobalThis. Source/JavaScriptCore: * API/JSCallbackObjectFunctions.h: (JSC::::finishCreation): - Don't pass the thisValue to JSGlobalObject::finishCreation. * JavaScriptCore.xcodeproj/project.pbxproj: - Added JSGlobalThis.h * jsc.cpp: (GlobalObject::finishCreation): - Don't pass the thisValue to JSGlobalObject::finishCreation. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::create): (JSC::JSGlobalObject::finishCreation): - finishCreation takes a JSGlobalThis, or thisValue is implicit. * runtime/JSGlobalThis.h: Added. (JSC::JSGlobalThis::create): (JSC::JSGlobalThis::JSGlobalThis): (JSC::JSGlobalThis::finishCreation): - Thin wrapper on JSNonFinalObject to allow type checking. * testRegExp.cpp: (GlobalObject::finishCreation): - Don't pass the thisValue to JSGlobalObject::finishCreation. Source/JavaScriptGlue: * JSRun.h: (JSGlueGlobalObject::create): - Don't pass the thisValue to JSGlobalObject::finishCreation. Source/WebCore: * ForwardingHeaders/runtime/JSGlobalThis.h: Added. - Added forwarding header. * bindings/js/JSDOMGlobalObject.cpp: (WebCore::JSDOMGlobalObject::finishCreation): * bindings/js/JSDOMGlobalObject.h: - finishCreation takes a JSGlobalThis, or thisValue is implicit. * bindings/js/JSDOMWindowShell.h: - Make the window shell a subclass of JSGlobalThis. * bindings/js/JSWorkerContextBase.cpp: (WebCore::JSWorkerContextBase::finishCreation): - Don't pass the thisValue to JSGlobalObject::finishCreation. * bindings/js/JSWorkerContextBase.h: * bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader): - Don't pass the thisValue to JSGlobalObject::finishCreation, for worker contexts. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@96836 268f45cc-cd09-0410-ab3c-d52691b4dbfc
453d6678