W3C home > Mailing lists > Public > public-script-coord@w3.org > January to March 2012

RE: Should binding section be rewritten more algorithmically?

From: Travis Leithead <travis.leithead@microsoft.com>
Date: Fri, 23 Mar 2012 18:53:49 +0000
To: Marcos Caceres <marcosscaceres@gmail.com>, public-script-coord <public-script-coord@w3.org>
Message-ID: <9768D477C67135458BF978A45BCF9B383828E9DA@TK5EX14MBXW604.wingroup.windeploy.ntdev.microsoft.com>
>-----Original Message-----
>From: Marcos Caceres [mailto:marcosscaceres@gmail.com]
>
>Is anyone else on this list implementing WebIDL? If so, I'm wondering if
>you would have an opinion as to whether the binding sections should be
>rewritten as algorithms (and more closely follow the style of ECMAScript5).

By "implementing" are you implementing the binding part or the syntax parsing part?

As I've mentioned before, IE9 used an earlier draft of WebIDL as the basis for our new JavaScript engine binding language for the DOM. It worked out pretty well, but there were a number of things we had to add as extensions to WebIDL for our own purposes.

>For example:
>
>Implementing an IDL exception is done as follows:
>
>1. Let IDL be the IDL fragment to be implemented.
>2. Let E be a new Function object.
>3. If the  [NoInterfaceObject] extended attribute was not used with IDL:
>__x. Let identifier be the identifier of IDL.
>__x. On the global object, call [[DefineOwnProperty]] with identifier, and
>Property Descriptor {[[Value]]: E, [[Writable]]: true, [[Enumerable]]:
>false, [[Configurable]]: true }, false.
>
>and so on…
>
>or am I the only person who is struggling to implement the spec in its
>current form?

WebIDL _could_ be re-worked as an algorithmic spec, but after a few readings, I think the current format works well enough--you quickly learn where you need to go to look something up, and it's well organized from that perspective. 

In other words, I don't have any complaints with the current format.
Received on Friday, 23 March 2012 18:54:27 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 May 2013 19:30:05 UTC