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

Unified Diff: src/string-iterator.js

Issue 1318043002: Native context: do not put public symbols and flags on the js builtins object. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix and rebase Created 5 years, 4 months 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/string.js ('k') | src/symbol.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/string-iterator.js
diff --git a/src/string-iterator.js b/src/string-iterator.js
index 4e51a12a2eda14e26fda37469d6e9516a95cf0a3..c55d967d78d4bcc08d755ce86b23672de1e2d5d5 100644
--- a/src/string-iterator.js
+++ b/src/string-iterator.js
@@ -13,10 +13,12 @@
var ArrayIteratorCreateResultObject;
var GlobalString = global.String;
+var iteratorSymbol = utils.ImportNow("iterator_symbol");
var stringIteratorIteratedStringSymbol =
- utils.GetPrivateSymbol("string_iterator_iterated_string_symbol");
+ utils.ImportNow("string_iterator_iterated_string_symbol");
var stringIteratorNextIndexSymbol =
- utils.GetPrivateSymbol("string_iterator_next_index_symbol");
+ utils.ImportNow("string_iterator_next_index_symbol");
+var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol");
utils.Import(function(from) {
ArrayIteratorCreateResultObject = from.ArrayIteratorCreateResultObject;
@@ -91,11 +93,11 @@ function StringPrototypeIterator() {
utils.InstallFunctions(StringIterator.prototype, DONT_ENUM, [
'next', StringIteratorNext
]);
-%AddNamedProperty(StringIterator.prototype, symbolToStringTag,
+%AddNamedProperty(StringIterator.prototype, toStringTagSymbol,
"String Iterator", READ_ONLY | DONT_ENUM);
-utils.SetFunctionName(StringPrototypeIterator, symbolIterator);
-%AddNamedProperty(GlobalString.prototype, symbolIterator,
+utils.SetFunctionName(StringPrototypeIterator, iteratorSymbol);
+%AddNamedProperty(GlobalString.prototype, iteratorSymbol,
StringPrototypeIterator, DONT_ENUM);
})
« no previous file with comments | « src/string.js ('k') | src/symbol.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698