-
commit-queue@webkit.org authored
https://bugs.webkit.org/show_bug.cgi?id=113219 Patch by Arnaud Renevier <a.renevier@sisa.samsung.com> on 2013-03-27 Reviewed by Kentaro Hara. Source/WebCore: When converting JSValue to native value in attribute setter, store the native value in a temporary variable. After this variable assignment, always check if an exception has been raised. Update binding tests. Test: fast/dom/exception-in-binding.html * bindings/scripts/CodeGeneratorJS.pm: (GenerateImplementation): (GetNativeType): (JSValueToNative): * bindings/scripts/test/JS/JSTestInterface.cpp: (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr): (WebCore::setJSTestInterfaceSupplementalStr2): (WebCore::setJSTestInterfaceSupplementalNode): * bindings/scripts/test/JS/JSTestObj.cpp: (WebCore::setJSTestObjConstructorStaticStringAttr): (WebCore::setJSTestObjEnumAttr): (WebCore::setJSTestObjShortAttr): (WebCore::setJSTestObjUnsignedShortAttr): (WebCore::setJSTestObjLongAttr): (WebCore::setJSTestObjLongLongAttr): (WebCore::setJSTestObjUnsignedLongLongAttr): (WebCore::setJSTestObjStringAttr): (WebCore::setJSTestObjTestObjAttr): (WebCore::setJSTestObjXMLObjAttr): (WebCore::setJSTestObjCreate): (WebCore::setJSTestObjReflectedStringAttr): (WebCore::setJSTestObjReflectedIntegralAttr): (WebCore::setJSTestObjReflectedUnsignedIntegralAttr): (WebCore::setJSTestObjReflectedBooleanAttr): (WebCore::setJSTestObjReflectedURLAttr): (WebCore::setJSTestObjReflectedCustomIntegralAttr): (WebCore::setJSTestObjReflectedCustomBooleanAttr): (WebCore::setJSTestObjReflectedCustomURLAttr): (WebCore::setJSTestObjTypedArrayAttr): (WebCore::setJSTestObjAttrWithGetterException): (WebCore::setJSTestObjAttrWithSetterException): (WebCore::setJSTestObjStringAttrWithGetterException): (WebCore::setJSTestObjStringAttrWithSetterException): (WebCore::setJSTestObjWithScriptStateAttribute): (WebCore::setJSTestObjWithScriptExecutionContextAttribute): (WebCore::setJSTestObjWithScriptStateAttributeRaises): (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises): (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute): (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises): (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute): (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute): (WebCore::setJSTestObjConditionalAttr1): (WebCore::setJSTestObjConditionalAttr2): (WebCore::setJSTestObjConditionalAttr3): (WebCore::setJSTestObjAnyAttribute): (WebCore::setJSTestObjMutablePoint): (WebCore::setJSTestObjImmutablePoint): (WebCore::setJSTestObjStrawberry): (WebCore::setJSTestObjStrictFloat): (WebCore::setJSTestObjId): (WebCore::setJSTestObjNullableLongSettableAttribute): (WebCore::setJSTestObjNullableStringValue): * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: (WebCore::setJSTestSerializedScriptValueInterfaceValue): (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue): * bindings/scripts/test/JS/JSTestTypedefs.cpp: (WebCore::setJSTestTypedefsUnsignedLongLongAttr): (WebCore::setJSTestTypedefsImmutableSerializedScriptValue): (WebCore::setJSTestTypedefsAttrWithGetterException): (WebCore::setJSTestTypedefsAttrWithSetterException): (WebCore::setJSTestTypedefsStringAttrWithGetterException): (WebCore::setJSTestTypedefsStringAttrWithSetterException): LayoutTests: * fast/dom/exception-in-binding-expected.txt: Added. * fast/dom/exception-in-binding.html: Added. * platform/chromium/TestExpectations: new test fails for now git-svn-id: http://svn.webkit.org/repository/webkit/trunk@147038 268f45cc-cd09-0410-ab3c-d52691b4dbfc
7b53ab4c