The JSC code generator doesn't generate correct code for Constructors
authortommyw@google.com <tommyw@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 23 Mar 2012 13:27:52 +0000 (13:27 +0000)
committertommyw@google.com <tommyw@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 23 Mar 2012 13:27:52 +0000 (13:27 +0000)
commit544b1b6a53049a768b3a11ee7fc0dda3b7cacaf2
treef3fb76030323abf65cf8ca3e75ee54430641e666
parent68e6dbcfba96bd170e0b7b008eb92029557aabe5
The JSC code generator doesn't generate correct code for Constructors
https://bugs.webkit.org/show_bug.cgi?id=82046

Reviewed by Kentaro Hara.

The main bulk of generated code for constructors uses the name jsConstructor
for the created object, and then calls GenerateParametersCheck which generates
code that uses the name castedThis.

* bindings/scripts/CodeGeneratorJS.pm:
(GenerateConstructorDefinition):
* bindings/scripts/test/JS/JSTestInterface.cpp:
(WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
* bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
(WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::JSTestObjConstructor::finishCreation):
(WebCore::JSTestObjConstructor::constructJSTestObj):
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
(WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
* bindings/scripts/test/TestObj.idl:
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::V8TestObj::constructorCallback):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@111856 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp
Source/WebCore/bindings/scripts/test/TestObj.idl
Source/WebCore/bindings/scripts/test/V8/V8TestObj.cpp