<?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>28124</bug_id>
          
          <creation_ts>2015-03-02 14:48:48 +0000</creation_ts>
          <short_desc>Issues in 4.5.11 (Maplike) and 4.5.12 (Setlike)</short_desc>
          <delta_ts>2019-02-28 13:21:34 +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>WebIDL</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="Jens Widell">jl</reporter>
          <assigned_to name="Cameron McCormack">cam</assigned_to>
          <cc>mike</cc>
    
    <cc>Ms2ger</cc>
    
    <cc>public-script-coord</cc>
          
          <qa_contact>public-webapps-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>118234</commentid>
    <comment_count>0</comment_count>
    <who name="Jens Widell">jl</who>
    <bug_when>2015-03-02 14:48:48 +0000</bug_when>
    <thetext>In the descriptions of the various maplike/setlike operations, there are some issues:

First, in e.g. &quot;4.5.11.4. get and has&quot;, there are the steps

 5. Let /map/ be the Map object that is the value of /O/’s [[BackingMap]] internal slot.

 ...

 7. Let /function/ be the result of calling the [[Get]] internal method of /O/ passing /name/ and /O/ as arguments.

Here, step 7 ought to call [[Get]] on /map/ from step 5, I think. Otherwise, step 7 would simply find the function that implements these steps. The same pattern repeats in the description of most maplike and setlike operations.

Second, in &quot;4.5.11.7. set&quot; and &quot;4.5.12.5. add and delete&quot;, the operations are ultimately defined as calling the corresponding function on the backing map/set and returning the result thereof. But Map.set() and Set.add() return the map/set object (i.e. &apos;this&apos;), which thus would mean that e.g. a maplike platform object&apos;s set() operation would return the internal [[BackingMap]] object to the calling script code. It would seem more reasonable to return the maplike platform object, after calling the backing map&apos;s set().</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>129578</commentid>
    <comment_count>1</comment_count>
    <who name="Ms2ger">Ms2ger</who>
    <bug_when>2019-02-28 13:21:34 +0000</bug_when>
    <thetext>Fixed in https://github.com/heycam/webidl/pull/47.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>