[Webkit-unassigned] [Bug 26398] Move IDL extended attributes to the location specified in WebIDL

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jul 12 01:03:21 PDT 2012


--- Comment #22 from Takashi Sakamoto <tasak at google.com>  2012-07-12 01:03:19 PST ---
(In reply to comment #19)
> Created an attachment (id=151870)
 --> (https://bugs.webkit.org/attachment.cgi?id=151870&action=review) [details]
> Patch

I removed diff for IDL files and added backwardCompatibleMode to parse the current WebKit IDL files.
Its default value is 1. This means that IDLParser.pm expects the current WebKit IDL files' grammar.

The following is the way to generate IDLParser.pm:
(1) Run the uploaded IDL ParserTemplate Code Generator script with the WebIDL grammar definition file.

  python IDLParserTemplateGenerator.py WebIDLGrammar.txt

The WebIDL grammar definition file is copied from http://www.w3.org/TR/2011/WD-WebIDL-20110712/#idl-grammar 's table and modified to support WebKit IDL files. i.e.

- Support the "module" which is not terminated by ";",
- Support "setter raises" and "getter raises",
- Support multiple parents,
- Support "int".
- Extended attribute can has "condition1|condition2" or "condition1&condition2"... ,
(the spec says, the extended attributes defined in this document only accept a more restricted syntax. 
The above extended attributes don't match the spec.)
- Move extended attributes' location,
- Extended attributes can be terminated by ",]". (According to the spec, the "," is wrong.)

The result is https://bugs.webkit.org/attachment.cgi?id=151682

I created one more WebIDL grammar to move extended attributes to the spec location. The difference between the previous grammar and this is:

- Not support "setter raises" and "getter raises". Support "setraises" and "getraises".
- Move extended attributes to the spec location,

The reason why I didn't use the latest spec is that "module" was removed from the spec.
I'm not sure what is the best way to remove "module"s from WebKit IDL files. So I used the last spec which supports "module".

(2) Merge two template codes and added the code to generate the same outputs as the original IDLParser.pm does.

Best regards,
Takashi Sakamoto

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