Revision: 22099
Author:   [email protected]
Date:     Mon Jun 30 14:37:07 2014 UTC
Log:      ES6: Add missing Set.prototype.keys function

https://people.mozilla.org/~jorendorff/es6-draft.html#sec-set.prototype.keys

The value of the keys property is just the initial value of the values
function.

BUG=v8:3411
LOG=Y
[email protected]

Review URL: https://codereview.chromium.org/353293003
http://code.google.com/p/v8/source/detail?r=22099

Modified:
 /branches/bleeding_edge/src/collection-iterator.js
 /branches/bleeding_edge/test/mjsunit/harmony/collection-iterator.js

=======================================
--- /branches/bleeding_edge/src/collection-iterator.js Fri Jun 27 13:48:37 2014 UTC +++ /branches/bleeding_edge/src/collection-iterator.js Mon Jun 30 14:37:07 2014 UTC
@@ -87,6 +87,7 @@

   InstallFunctions($Set.prototype, DONT_ENUM, $Array(
     'entries', SetEntries,
+    'keys', SetValues,
     'values', SetValues
   ));

=======================================
--- /branches/bleeding_edge/test/mjsunit/harmony/collection-iterator.js Tue Jun 3 00:34:01 2014 UTC +++ /branches/bleeding_edge/test/mjsunit/harmony/collection-iterator.js Mon Jun 30 14:37:07 2014 UTC
@@ -37,6 +37,11 @@
 })();


+(function TestSetIteratorKeys() {
+  assertEquals(Set.prototype.keys, Set.prototype.values);
+})();
+
+
 (function TestSetIteratorEntries() {
   var s = new Set;
   s.add(1);

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to