Introduce string/regexp related public symbols.
R=littledan@chromium.org BUG=v8:4305, v8:4343, v8:4344, v8:4345 LOG=N Review URL: https://codereview.chromium.org/1424113003 Cr-Commit-Position: refs/heads/master@{#31643}
This commit is contained in:
parent
e933b091df
commit
6812883494
@ -354,12 +354,16 @@ namespace internal {
|
|||||||
V(string_iterator_next_index_symbol) \
|
V(string_iterator_next_index_symbol) \
|
||||||
V(uninitialized_symbol)
|
V(uninitialized_symbol)
|
||||||
|
|
||||||
#define PUBLIC_SYMBOL_LIST(V) \
|
#define PUBLIC_SYMBOL_LIST(V) \
|
||||||
V(has_instance_symbol, Symbol.hasInstance) \
|
V(has_instance_symbol, Symbol.hasInstance) \
|
||||||
V(is_regexp_symbol, Symbol.isRegExp) \
|
V(is_regexp_symbol, Symbol.isRegExp) \
|
||||||
V(iterator_symbol, Symbol.iterator) \
|
V(iterator_symbol, Symbol.iterator) \
|
||||||
V(to_primitive_symbol, Symbol.toPrimitive) \
|
V(match_symbol, Symbol.match) \
|
||||||
V(to_string_tag_symbol, Symbol.toStringTag) \
|
V(replace_symbol, Symbol.replace) \
|
||||||
|
V(search_symbol, Symbol.search) \
|
||||||
|
V(split_symbol, Symbol.split) \
|
||||||
|
V(to_primitive_symbol, Symbol.toPrimitive) \
|
||||||
|
V(to_string_tag_symbol, Symbol.toStringTag) \
|
||||||
V(unscopables_symbol, Symbol.unscopables)
|
V(unscopables_symbol, Symbol.unscopables)
|
||||||
|
|
||||||
// Well-Known Symbols are "Public" symbols, which have a bit set which causes
|
// Well-Known Symbols are "Public" symbols, which have a bit set which causes
|
||||||
|
@ -19,7 +19,11 @@ var isConcatSpreadableSymbol =
|
|||||||
var isRegExpSymbol = utils.ImportNow("is_regexp_symbol");
|
var isRegExpSymbol = utils.ImportNow("is_regexp_symbol");
|
||||||
var iteratorSymbol = utils.ImportNow("iterator_symbol");
|
var iteratorSymbol = utils.ImportNow("iterator_symbol");
|
||||||
var MakeTypeError;
|
var MakeTypeError;
|
||||||
|
var matchSymbol = utils.ImportNow("match_symbol");
|
||||||
var ObjectGetOwnPropertyKeys;
|
var ObjectGetOwnPropertyKeys;
|
||||||
|
var replaceSymbol = utils.ImportNow("replace_symbol");
|
||||||
|
var searchSymbol = utils.ImportNow("search_symbol");
|
||||||
|
var splitSymbol = utils.ImportNow("split_symbol");
|
||||||
var toPrimitiveSymbol = utils.ImportNow("to_primitive_symbol");
|
var toPrimitiveSymbol = utils.ImportNow("to_primitive_symbol");
|
||||||
var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol");
|
var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol");
|
||||||
var unscopablesSymbol = utils.ImportNow("unscopables_symbol");
|
var unscopablesSymbol = utils.ImportNow("unscopables_symbol");
|
||||||
@ -96,6 +100,11 @@ utils.InstallConstants(GlobalSymbol, [
|
|||||||
// "isConcatSpreadable", isConcatSpreadableSymbol,
|
// "isConcatSpreadable", isConcatSpreadableSymbol,
|
||||||
// "isRegExp", isRegExpSymbol,
|
// "isRegExp", isRegExpSymbol,
|
||||||
"iterator", iteratorSymbol,
|
"iterator", iteratorSymbol,
|
||||||
|
// TODO(yangguo): expose when implemented.
|
||||||
|
// "match", matchSymbol,
|
||||||
|
// "replace", replaceSymbol,
|
||||||
|
// "search", searchSymbol,
|
||||||
|
// "split, splitSymbol,
|
||||||
"toPrimitive", toPrimitiveSymbol,
|
"toPrimitive", toPrimitiveSymbol,
|
||||||
// TODO(dslomov, caitp): Currently defined in harmony-tostring.js ---
|
// TODO(dslomov, caitp): Currently defined in harmony-tostring.js ---
|
||||||
// Move here when shipping
|
// Move here when shipping
|
||||||
|
Loading…
Reference in New Issue
Block a user