Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1074)

Unified Diff: src/symbol.js

Issue 722723002: Move public symbols to the root set. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/runtime/runtime-scopes.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/symbol.js
diff --git a/src/symbol.js b/src/symbol.js
index b4ae708e594a18c81a614e20dcd393ddf3fa22cd..d9cf79265f33320a500a04cd5532440cb53bc929 100644
--- a/src/symbol.js
+++ b/src/symbol.js
@@ -8,6 +8,14 @@
// in runtime.js:
// var $Array = global.Array;
+// And requires following symbols to be set in the bootstrapper during genesis:
+// - symbolHasInstance
+// - symbolIsConcatSpreadable
+// - symbolIsRegExp
+// - symbolIterator
+// - symbolToStringTag
+// - symbolUnscopables
+
var $Symbol = global.Symbol;
// -------------------------------------------------------------------
@@ -40,15 +48,6 @@ function SymbolValueOf() {
}
-function InternalSymbol(key) {
- var internal_registry = %SymbolRegistry().for_intern;
- if (IS_UNDEFINED(internal_registry[key])) {
- internal_registry[key] = %CreateSymbol(key);
- }
- return internal_registry[key];
-}
-
-
function SymbolFor(key) {
key = TO_STRING_INLINE(key);
var registry = %SymbolRegistry();
@@ -76,17 +75,6 @@ function ObjectGetOwnPropertySymbols(obj) {
return ObjectGetOwnPropertyKeys(obj, PROPERTY_ATTRIBUTES_STRING);
}
-
-//-------------------------------------------------------------------
-
-var symbolHasInstance = InternalSymbol("Symbol.hasInstance");
-var symbolIsConcatSpreadable = InternalSymbol("Symbol.isConcatSpreadable");
-var symbolIsRegExp = InternalSymbol("Symbol.isRegExp");
-var symbolIterator = InternalSymbol("Symbol.iterator");
-var symbolToStringTag = InternalSymbol("Symbol.toStringTag");
-var symbolUnscopables = InternalSymbol("Symbol.unscopables");
-
-
//-------------------------------------------------------------------
function SetUpSymbol() {
« no previous file with comments | « src/runtime/runtime-scopes.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698