haikuwebkit/LayoutTests/js/strict-throw-type-error-exp...

21 lines
624 B
Plaintext
Raw Permalink Normal View History

https://bugs.webkit.org/show_bug.cgi?id=75429 ThrowTypeError should be a singleton object Reviewed by Sam Weinig. Source/JavaScriptCore: Per section 13.2.3 of the spec. We could change setAccessorDescriptor to be able to share the global GetterSetter object, rather than storing the accessor functions and creating a new GetterSetter in defineProperty - but this won't be a small change to PropertyDescriptors (and would probably mean making GetterSetter objects immutable?) - so I'll leave that for another patch. * JavaScriptCore.exp: - don't export setAccessorDescriptor * runtime/Arguments.cpp: (JSC::Arguments::createStrictModeCallerIfNecessary): (JSC::Arguments::createStrictModeCalleeIfNecessary): - call throwTypeErrorGetterSetter instead of createTypeErrorFunction * runtime/Error.cpp: * runtime/Error.h: - remove createTypeErrorFunction * runtime/JSFunction.cpp: * runtime/JSFunction.h: - remove unused createDescriptorForThrowingProperty * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::reset): (JSC::JSGlobalObject::visitChildren): - removed m_strictModeTypeErrorFunctionStructure. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::internalFunctionStructure): - removed m_strictModeTypeErrorFunctionStructure. * runtime/PropertyDescriptor.cpp: (JSC::PropertyDescriptor::setAccessorDescriptor): - changed to take a GetterSetter * runtime/PropertyDescriptor.h: - changed to take a GetterSetter LayoutTests: Per section 13.2.3 of the spec. * fast/js/basic-strict-mode-expected.txt: - ThrowTypeError is a singleton, so cannot generate property-specific error messages. * fast/js/script-tests/strict-throw-type-error.js: Added. * fast/js/strict-throw-type-error-expected.txt: Added. * fast/js/strict-throw-type-error.html: Added. - added test case that ThrowTypeError is a singleton Canonical link: https://commits.webkit.org/92255@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@103958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-01-03 21:05:46 +00:00
ThrowTypeError is a singleton object
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS functionCaller1 === functionCaller2 is true
PASS functionCaller1 === functionArguments1 is true
2016-11-18 00:37:28 +00:00
PASS argumentsCaller1 is undefined
https://bugs.webkit.org/show_bug.cgi?id=75429 ThrowTypeError should be a singleton object Reviewed by Sam Weinig. Source/JavaScriptCore: Per section 13.2.3 of the spec. We could change setAccessorDescriptor to be able to share the global GetterSetter object, rather than storing the accessor functions and creating a new GetterSetter in defineProperty - but this won't be a small change to PropertyDescriptors (and would probably mean making GetterSetter objects immutable?) - so I'll leave that for another patch. * JavaScriptCore.exp: - don't export setAccessorDescriptor * runtime/Arguments.cpp: (JSC::Arguments::createStrictModeCallerIfNecessary): (JSC::Arguments::createStrictModeCalleeIfNecessary): - call throwTypeErrorGetterSetter instead of createTypeErrorFunction * runtime/Error.cpp: * runtime/Error.h: - remove createTypeErrorFunction * runtime/JSFunction.cpp: * runtime/JSFunction.h: - remove unused createDescriptorForThrowingProperty * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::reset): (JSC::JSGlobalObject::visitChildren): - removed m_strictModeTypeErrorFunctionStructure. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::internalFunctionStructure): - removed m_strictModeTypeErrorFunctionStructure. * runtime/PropertyDescriptor.cpp: (JSC::PropertyDescriptor::setAccessorDescriptor): - changed to take a GetterSetter * runtime/PropertyDescriptor.h: - changed to take a GetterSetter LayoutTests: Per section 13.2.3 of the spec. * fast/js/basic-strict-mode-expected.txt: - ThrowTypeError is a singleton, so cannot generate property-specific error messages. * fast/js/script-tests/strict-throw-type-error.js: Added. * fast/js/strict-throw-type-error-expected.txt: Added. * fast/js/strict-throw-type-error.html: Added. - added test case that ThrowTypeError is a singleton Canonical link: https://commits.webkit.org/92255@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@103958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-01-03 21:05:46 +00:00
PASS functionCaller1 === argumentsCallee1 is true
PASS boundCaller1 is undefined
PASS boundArguments1 is undefined
https://bugs.webkit.org/show_bug.cgi?id=75429 ThrowTypeError should be a singleton object Reviewed by Sam Weinig. Source/JavaScriptCore: Per section 13.2.3 of the spec. We could change setAccessorDescriptor to be able to share the global GetterSetter object, rather than storing the accessor functions and creating a new GetterSetter in defineProperty - but this won't be a small change to PropertyDescriptors (and would probably mean making GetterSetter objects immutable?) - so I'll leave that for another patch. * JavaScriptCore.exp: - don't export setAccessorDescriptor * runtime/Arguments.cpp: (JSC::Arguments::createStrictModeCallerIfNecessary): (JSC::Arguments::createStrictModeCalleeIfNecessary): - call throwTypeErrorGetterSetter instead of createTypeErrorFunction * runtime/Error.cpp: * runtime/Error.h: - remove createTypeErrorFunction * runtime/JSFunction.cpp: * runtime/JSFunction.h: - remove unused createDescriptorForThrowingProperty * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::reset): (JSC::JSGlobalObject::visitChildren): - removed m_strictModeTypeErrorFunctionStructure. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::internalFunctionStructure): - removed m_strictModeTypeErrorFunctionStructure. * runtime/PropertyDescriptor.cpp: (JSC::PropertyDescriptor::setAccessorDescriptor): - changed to take a GetterSetter * runtime/PropertyDescriptor.h: - changed to take a GetterSetter LayoutTests: Per section 13.2.3 of the spec. * fast/js/basic-strict-mode-expected.txt: - ThrowTypeError is a singleton, so cannot generate property-specific error messages. * fast/js/script-tests/strict-throw-type-error.js: Added. * fast/js/strict-throw-type-error-expected.txt: Added. * fast/js/strict-throw-type-error.html: Added. - added test case that ThrowTypeError is a singleton Canonical link: https://commits.webkit.org/92255@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@103958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-01-03 21:05:46 +00:00
PASS functionCaller2 === functionArguments2 is true
2016-11-18 00:37:28 +00:00
PASS argumentsCaller2 is undefined
https://bugs.webkit.org/show_bug.cgi?id=75429 ThrowTypeError should be a singleton object Reviewed by Sam Weinig. Source/JavaScriptCore: Per section 13.2.3 of the spec. We could change setAccessorDescriptor to be able to share the global GetterSetter object, rather than storing the accessor functions and creating a new GetterSetter in defineProperty - but this won't be a small change to PropertyDescriptors (and would probably mean making GetterSetter objects immutable?) - so I'll leave that for another patch. * JavaScriptCore.exp: - don't export setAccessorDescriptor * runtime/Arguments.cpp: (JSC::Arguments::createStrictModeCallerIfNecessary): (JSC::Arguments::createStrictModeCalleeIfNecessary): - call throwTypeErrorGetterSetter instead of createTypeErrorFunction * runtime/Error.cpp: * runtime/Error.h: - remove createTypeErrorFunction * runtime/JSFunction.cpp: * runtime/JSFunction.h: - remove unused createDescriptorForThrowingProperty * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::reset): (JSC::JSGlobalObject::visitChildren): - removed m_strictModeTypeErrorFunctionStructure. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::internalFunctionStructure): - removed m_strictModeTypeErrorFunctionStructure. * runtime/PropertyDescriptor.cpp: (JSC::PropertyDescriptor::setAccessorDescriptor): - changed to take a GetterSetter * runtime/PropertyDescriptor.h: - changed to take a GetterSetter LayoutTests: Per section 13.2.3 of the spec. * fast/js/basic-strict-mode-expected.txt: - ThrowTypeError is a singleton, so cannot generate property-specific error messages. * fast/js/script-tests/strict-throw-type-error.js: Added. * fast/js/strict-throw-type-error-expected.txt: Added. * fast/js/strict-throw-type-error.html: Added. - added test case that ThrowTypeError is a singleton Canonical link: https://commits.webkit.org/92255@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@103958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-01-03 21:05:46 +00:00
PASS functionCaller2 === argumentsCallee2 is true
PASS boundCaller2 is undefined
PASS boundArguments2 is undefined
https://bugs.webkit.org/show_bug.cgi?id=75429 ThrowTypeError should be a singleton object Reviewed by Sam Weinig. Source/JavaScriptCore: Per section 13.2.3 of the spec. We could change setAccessorDescriptor to be able to share the global GetterSetter object, rather than storing the accessor functions and creating a new GetterSetter in defineProperty - but this won't be a small change to PropertyDescriptors (and would probably mean making GetterSetter objects immutable?) - so I'll leave that for another patch. * JavaScriptCore.exp: - don't export setAccessorDescriptor * runtime/Arguments.cpp: (JSC::Arguments::createStrictModeCallerIfNecessary): (JSC::Arguments::createStrictModeCalleeIfNecessary): - call throwTypeErrorGetterSetter instead of createTypeErrorFunction * runtime/Error.cpp: * runtime/Error.h: - remove createTypeErrorFunction * runtime/JSFunction.cpp: * runtime/JSFunction.h: - remove unused createDescriptorForThrowingProperty * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::reset): (JSC::JSGlobalObject::visitChildren): - removed m_strictModeTypeErrorFunctionStructure. * runtime/JSGlobalObject.h: (JSC::JSGlobalObject::internalFunctionStructure): - removed m_strictModeTypeErrorFunctionStructure. * runtime/PropertyDescriptor.cpp: (JSC::PropertyDescriptor::setAccessorDescriptor): - changed to take a GetterSetter * runtime/PropertyDescriptor.h: - changed to take a GetterSetter LayoutTests: Per section 13.2.3 of the spec. * fast/js/basic-strict-mode-expected.txt: - ThrowTypeError is a singleton, so cannot generate property-specific error messages. * fast/js/script-tests/strict-throw-type-error.js: Added. * fast/js/strict-throw-type-error-expected.txt: Added. * fast/js/strict-throw-type-error.html: Added. - added test case that ThrowTypeError is a singleton Canonical link: https://commits.webkit.org/92255@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@103958 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-01-03 21:05:46 +00:00
PASS successfullyParsed is true
TEST COMPLETE