On Tue, 7 Sep 2010, Adam Barth wrote: > > I think the bitfield approach is better. The current approach doesn't > work very well in strongly typed languages. Although we might think > that these APIs will be used most-often from JavaScript, these APIs are > language neutral and should work in a variety of settings (e.g., as part > of the NPAPI). Baking in assumptions that APIs are used by dynamically > typed language isn't good for the web platform in the long term.
The APIs don't have to be identical in each language. For example, I would expect a C++ port of ValidityState: http://www.whatwg.org/specs/web-apps/current-work/complete.html#validitystate ...to be implemented as a bitfield with constants, rather than as an object with fields. Should anyone want to implement that interface in such a language, then would be a time to provide suitable IDL for that case. -- Ian Hickson U+1047E )\._.,--....,'``. fL http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,. Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'