The important functionality: LGTM

I'm not sure that we should install Symbol.x if we do not support x, where x is a certain feature. For example, one might expect us to support @@create because we have Symbol.create. I think adding these once we support the feature would
allow code to use feature detection.

There are some details that need more work and expanded tests.


https://codereview.chromium.org/203243004/diff/50010/src/symbol.js
File src/symbol.js (right):

https://codereview.chromium.org/203243004/diff/50010/src/symbol.js#newcode68
src/symbol.js:68: if (!('internal' in registry)) {
Maybe this could have been

if (IS_UNDEFINED(registry.internal)) {

since the in operator is slow.

https://codereview.chromium.org/203243004/diff/50010/src/symbol.js#newcode121
src/symbol.js:121: var symbolCreate = InternalSymbol("@@create");
Doesn't '@' in a property name cause the object to become slow?

The [[Description]] should be "Symbol.create".

http://people.mozilla.org/~jorendorff/es6-draft.html#sec-well-known-symbols

https://codereview.chromium.org/203243004/diff/50010/src/symbol.js#newcode138
src/symbol.js:138: %SetProperty($Symbol, "create", symbolCreate,
DONT_ENUM);
Also, non writable, non configurable.

http://people.mozilla.org/~jorendorff/es6-draft.html#sec-symbol.create

https://codereview.chromium.org/203243004/

--
--
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