Bug 110510 - Nodes should not have attributes property
Summary: Nodes should not have attributes property
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Erik Arvidsson
URL: http://dom.spec.whatwg.org/#node
Keywords: WebExposed
Depends on:
Blocks:
 
Reported: 2013-02-21 13:35 PST by Erik Arvidsson
Modified: 2013-02-21 16:29 PST (History)
6 users (show)

See Also:


Attachments
Patch (4.80 KB, patch)
2013-02-21 14:11 PST, Erik Arvidsson
no flags Details | Formatted Diff | Diff
Patch (12.83 KB, patch)
2013-02-21 15:14 PST, Erik Arvidsson
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Comment 1 Erik Arvidsson 2013-02-21 13:37:15 PST
Also, hasAttributes is in the wrong idl file.

The following should all be moved to Element.idl

attributes
hasAttributes
Comment 2 Erik Arvidsson 2013-02-21 14:11:06 PST
Created attachment 189599 [details]
Patch
Comment 3 Adam Barth 2013-02-21 14:50:14 PST
Comment on attachment 189599 [details]
Patch

Are we worried about the compatibility impact of this change?
Comment 4 WebKit Review Bot 2013-02-21 14:50:49 PST
Comment on attachment 189599 [details]
Patch

Attachment 189599 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/16695354

New failing tests:
fast/dom/Node/initial-values.html
Comment 5 Erik Arvidsson 2013-02-21 15:07:35 PST
(In reply to comment #3)
> (From update of attachment 189599 [details])
> Are we worried about the compatibility impact of this change?

Not really.

attributes returned null on non Elements before and now it will return undefined. This part I'm completely confident that it is safe.

It is possible that someone has code out there that calls hasAttributes() on an Attr, Text, DocumentFragment or Document but it unlikely and wrong.

I could definitely split this into two patches just to make things easier to rollback in case of unforeseen issues.
Comment 6 Erik Arvidsson 2013-02-21 15:14:01 PST
Created attachment 189610 [details]
Patch
Comment 7 Adam Barth 2013-02-21 15:52:01 PST
Comment on attachment 189610 [details]
Patch

Ok.
Comment 8 WebKit Review Bot 2013-02-21 16:29:03 PST
Comment on attachment 189610 [details]
Patch

Clearing flags on attachment: 189610

Committed r143663: <http://trac.webkit.org/changeset/143663>
Comment 9 WebKit Review Bot 2013-02-21 16:29:06 PST
All reviewed patches have been landed.  Closing bug.