[Webkit-unassigned] [Bug 65839] CodeGenerator*.pm should support Web IDL Constructor attribute

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Aug 15 18:58:28 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=65839





--- Comment #6 from Kentaro Hara <haraken at google.com>  2011-08-15 18:58:28 PST ---
Dominic: I confirmed that the patch passes all tests. Basically, this patch intends to replace 6 custom constructors (EventSource, FileReader, SharedWorker, WebKitCSSMatrix, Worker, XSLTProcessor) with the Web IDL [Constructor] extended attribute without changing their original behaviors. 

However, this patch changes an exception thrown by EventSource, SharedWorker and Worker constructors, when an argument for them is not valid. Specifically, without this patch, these constructors throw "throwError("Not enough arguments", V8Proxy::SyntaxError)" from constructorCallback(). On the other hand, with this patch, these constructors throw "throwError(SYNTAX_ERR)" from XXXXXX::create(). In other words, this patch moves the code for throwing an exception from constructorCallback() to inside XXXXXX::create(). (Currently, some constructors throw the syntax error from constructorCallback(), and others throw it from XXXXXX::create(). I want to make them consistent, so that they throw the syntax error from XXXXXX::create().)


Since this patch is too big to commit without regressions, I would like to commit it in the following steps. 

[1] Make the change of exceptions in EventSource constructor.
[2] Make the change of exceptions in SharedWorker constructor.
[3] Make the change of exceptions in Worker constructor.
[4] Implement the Web IDL Constructor extended attribute in IDLParser.pm and CodeGeneratorV8.pm. (How can I write the tests for this?)
[5] Replace EventSource constructor with the Web IDL Constructor extended attribute.
[6] Replace FileReader constructor with the Web IDL Constructor extended attribute.
[7] Replace SharedWorker constructor with the Web IDL Constructor extended attribute.
[8] Replace WebKitCSSMatrix constructor with the Web IDL Constructor extended attribute.
[9] Replace Worker constructor with the Web IDL Constructor extended attribute.
[10] Replace XSLTProcessor constructor with the Web IDL Constructor extended attribute.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list