RESOLVED FIXED 40750
Differences in error reporting for overloaded methods causing fast/canvas/webgl/texImageTest.html to fail
https://bugs.webkit.org/show_bug.cgi?id=40750
Summary Differences in error reporting for overloaded methods causing fast/canvas/web...
Kenneth Russell
Reported 2010-06-16 17:36:28 PDT
The automatic code generation for overloaded methods recently added to CodeGeneratorJS.pm and CodeGeneratorV8.pm differs in its error reporting. CodeGeneratorJS.pm throws a TypeError when none of the overloaded methods match, while CodeGeneratorV8.pm throws a SYNTAX_ERR DOM exception. The Web IDL specification states that TypeError should be thrown; the concept of a syntax error is not even mentioned in the spec. This difference in behavior is causing fast/canvas/webgl/texImageTest-expected.txt to fail in Chromium. Currently this is the only layout test which exercises the failure case of the autogenerated overloaded method bindings.
Attachments
Patch (7.62 KB, patch)
2010-06-16 18:13 PDT, Kenneth Russell
oliver: review+
kbr: commit-queue-
Kenneth Russell
Comment 1 2010-06-16 18:13:04 PDT
Created attachment 58948 [details] Patch From the ChangeLog: Added V8Proxy::throwTypeError() and throwSyntaxError for parity with JSC::throwTypeError() and throwSyntaxError. Changed CodeGeneratorV8.pm to use throwTypeError for overload resolution failures. Revised CodeGeneratorJS.pm to use throwVMTypeError instead of manual call to JSValue::encode. Deleted now-unnecessary Chromium expectations for fast/canvas/webgl/texImageTest.html.
Kenneth Russell
Comment 2 2010-06-17 10:41:08 PDT
Note You need to log in before you can comment on or make changes to this bug.