<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>21986</bug_id>
          
          <creation_ts>2013-05-09 15:36:58 +0000</creation_ts>
          <short_desc>AttrExodus: Element.attributes needs to have a named getter</short_desc>
          <delta_ts>2014-08-18 11:21:43 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebAppsWG</product>
          <component>DOM</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ms2ger">Ms2ger</reporter>
          <assigned_to name="Anne">annevk</assigned_to>
          <cc>bruant.d</cc>
    
    <cc>erik.arvidsson</cc>
    
    <cc>mike</cc>
    
    <cc>philipj</cc>
    
    <cc>www-dom</cc>
          
          <qa_contact>public-webapps-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>87494</commentid>
    <comment_count>0</comment_count>
    <who name="Ms2ger">Ms2ger</who>
    <bug_when>2013-05-09 15:36:58 +0000</bug_when>
    <thetext>We broke this (intermittently) and got noticed:

https://bugzilla.mozilla.org/show_bug.cgi?id=869796
https://bugzilla.mozilla.org/show_bug.cgi?id=868834</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88418</commentid>
    <comment_count>1</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-05-30 05:38:07 +0000</bug_when>
    <thetext>*sad panda*</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>90488</commentid>
    <comment_count>2</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-07-09 15:54:28 +0000</bug_when>
    <thetext>Okay, so what interface should we introduce here?

http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-1780488922 is the original solution.

I called it AttrList as it&apos;s clearly not a Map in the JavaScript sense. I removed the methods that did not seem needed, but maybe they are?

interface AttrList {
  getter Attr (DOMString name);
  getter Attr item(unsigned long index);
  unsigned long length;
}

I guess because of the named getter adding ArrayClass would be problematic.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>90491</commentid>
    <comment_count>3</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-07-09 16:07:20 +0000</bug_when>
    <thetext>http://mxr.mozilla.org/mozilla-central/source/dom/webidl/MozNamedAttrMap.webidl note the ? after Attr in particular.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102882</commentid>
    <comment_count>4</comment_count>
    <who name="Philip Jägenstedt">philipj</who>
    <bug_when>2014-03-25 16:56:07 +0000</bug_when>
    <thetext>If the interface needs to stay, why bother changing the name?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102883</commentid>
    <comment_count>5</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2014-03-25 17:06:53 +0000</bug_when>
    <thetext>You want to keep the name NamedNodeMap from DOM Level 3 Core?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102885</commentid>
    <comment_count>6</comment_count>
    <who name="Philip Jägenstedt">philipj</who>
    <bug_when>2014-03-25 17:25:03 +0000</bug_when>
    <thetext>I don&apos;t feel strongly about it, just curious. In order to determine which bits of the API need to stay I just sent this review for more use counters in Blink:
https://codereview.chromium.org/211363003</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102888</commentid>
    <comment_count>7</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2014-03-25 18:07:55 +0000</bug_when>
    <thetext>Mainly since if we are keeping this API around and it is being exposed to the web, we might as well try to keep it somewhat sane.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102892</commentid>
    <comment_count>8</comment_count>
    <who name="Philip Jägenstedt">philipj</who>
    <bug_when>2014-03-25 18:28:35 +0000</bug_when>
    <thetext>Unfortunately it currently doesn&apos;t seem possibly to count access to the interface object itself (e.g. using x instanceof NamedNodeMap) so I can&apos;t tell if changing it is safe. It seems fairly likely to be safe, though.

Anyway, the use counters have landed now, data will show up here:

NamedNodeMapGetNamedItem: http://www.chromestatus.com/metrics/feature/timeline/popularity/306
NamedNodeMapSetNamedItem: http://www.chromestatus.com/metrics/feature/timeline/popularity/307
NamedNodeMapRemoveNamedItem: http://www.chromestatus.com/metrics/feature/timeline/popularity/308
NamedNodeMapItem: http://www.chromestatus.com/metrics/feature/timeline/popularity/309
NamedNodeMapGetNamedItemNS: http://www.chromestatus.com/metrics/feature/timeline/popularity/310
NamedNodeMapSetNamedItemNS: http://www.chromestatus.com/metrics/feature/timeline/popularity/311
NamedNodeMapRemoveNamedItemNS: http://www.chromestatus.com/metrics/feature/timeline/popularity/312</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>110223</commentid>
    <comment_count>9</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2014-08-18 11:21:43 +0000</bug_when>
    <thetext>Philip, that seems encouraging. I added get/remove as well as their NS counterparts since we are stuck with namespaced attributes I think. I did not add the methods that deal with Attr objects since those would require a link between Attr objects and elements and that would be sad as you pointed out.

https://github.com/whatwg/dom/commit/8af48267390b971a2ac02c7005ba42c08264b7e1

New issues in new bugs I guess.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>