Bug 43224 - [V8] "delete" on IDL attributes that reflect DOM attributes does not match Firefox/Opera
Summary: [V8] "delete" on IDL attributes that reflect DOM attributes does not match Fi...
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Linux
: P2 Minor
Assignee: Nate Chapin
Depends on: 49739
  Show dependency treegraph
Reported: 2010-07-29 18:00 PDT by Aryeh Gregor
Modified: 2013-05-29 09:37 PDT (History)
5 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Aryeh Gregor 2010-07-29 18:00:23 PDT
data:text/html,<!doctype html>
 var el = document.createElement("a");
 delete el.id;
 alert(typeof el.id);

Chrome dev channel (6.0.472.0 (Official Build 53024) dev, WebKit 534.3) outputs "undefined".  Firefox and Opera output "string".  Discussion in #whatwg concluded that the relevant spec here is WebIDL:


But no one who was awake was able to decipher what it actually required here.  WebKit seems like the one that's wrong here, but I'm not totally sure on that.
Comment 1 Aryeh Gregor 2010-07-29 18:06:08 PDT
Maciej Stachowiak reports that the test gives "string" in Safari, so it's presumably a bug in the V8 bindings.
Comment 2 James Robinson 2010-07-29 18:06:23 PDT
Hey Nate, looks like a bindings generation bug.
Comment 3 Dominic Cooney 2011-06-16 07:20:52 PDT
This bug is a consequence of the way V8 bindings are generated. V8 generates IDL attributes as properties on the object. The Web IDL spec specifies them as getters and setters on the object's prototype [1]. If bug 49739 was fixed, this bug would also be fixed as a natural consequence.

[1] <http://dev.w3.org/2006/webapi/WebIDL/#es-attributes>