Bug 127358

Summary: Improve the bindings of NodeList's name accessor
Product: WebKit Reporter: Benjamin Poulain <benjamin>
Component: New BugsAssignee: Benjamin Poulain <benjamin>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, commit-queue, esprehn+autocc, ggaren, kangil.han, kondapallykalyan
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch ggaren: review+

Benjamin Poulain
Reported 2014-01-21 11:35:15 PST
Improve the bindings of NodeList's name accessor
Attachments
Patch (3.82 KB, patch)
2014-01-21 11:43 PST, Benjamin Poulain
no flags
Patch (6.26 KB, patch)
2014-01-23 17:20 PST, Benjamin Poulain
ggaren: review+
Benjamin Poulain
Comment 1 2014-01-21 11:43:12 PST
Sam Weinig
Comment 2 2014-01-21 22:01:03 PST
Comment on attachment 221768 [details] Patch Is this something we can extend to all the nameGetters?
Benjamin Poulain
Comment 3 2014-01-22 20:23:36 PST
(In reply to comment #2) > (From update of attachment 221768 [details]) > Is this something we can extend to all the nameGetters? It seems indeed that several other classes suffer from the same issue. If someone can confirm this patch is correct, I'll change other objects. It may be a good idea to nuke the pair canGetItemsForName()-nameGetter() entirely. Any opinion?
Geoffrey Garen
Comment 4 2014-01-23 15:03:38 PST
Comment on attachment 221768 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=221768&action=review r=me > Source/WebCore/bindings/js/JSNodeListCustom.cpp:57 > + slot.setValue(this, ReadOnly | DontDelete | DontEnum, toJS(exec, globalObject(), item)); I think this works. Please add a test to double-check that you haven't changed behavior of this property according to for-in enumeration and/or Object.getOwnPropertyDescriptor. Those are our best ways to test where the attributes set on the property are correct.
Benjamin Poulain
Comment 5 2014-01-23 17:20:43 PST
Geoffrey Garen
Comment 6 2014-01-23 19:15:17 PST
Comment on attachment 222049 [details] Patch r=me
Benjamin Poulain
Comment 7 2014-01-26 02:26:53 PST
Note You need to log in before you can comment on or make changes to this bug.