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

Unified Diff: src/bootstrapper.cc

Issue 1558543002: Add a --harmony-species flag, defining @@species on constructors (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years 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 | « BUILD.gn ('k') | src/flag-definitions.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index 93a8b44cc76a20f5ead4c98ab508910aa5fac607..9d74620af406b0cfbdbe9dd973777de517f8f2b0 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -2117,6 +2117,7 @@ void Bootstrapper::ExportExperimentalFromRuntime(Isolate* isolate,
INITIALIZE_FLAG(FLAG_harmony_tostring)
INITIALIZE_FLAG(FLAG_harmony_tolength)
+ INITIALIZE_FLAG(FLAG_harmony_species)
#undef INITIALIZE_FLAG
}
@@ -2334,6 +2335,13 @@ void Genesis::InitializeGlobal_harmony_proxies() {
}
+void Genesis::InitializeGlobal_harmony_species() {
+ if (!FLAG_harmony_species) return;
+ InstallPublicSymbol(factory(), native_context(), "species",
+ factory()->species_symbol());
+}
+
+
Handle<JSFunction> Genesis::InstallInternalArray(Handle<JSObject> target,
const char* name,
ElementsKind elements_kind) {
@@ -2665,6 +2673,8 @@ bool Genesis::InstallExperimentalNatives() {
static const char* harmony_sloppy_natives[] = {nullptr};
static const char* harmony_sloppy_function_natives[] = {nullptr};
static const char* harmony_sloppy_let_natives[] = {nullptr};
+ static const char* harmony_species_natives[] = {"native harmony-species.js",
+ nullptr};
static const char* harmony_unicode_regexps_natives[] = {
"native harmony-unicode-regexps.js", nullptr};
static const char* harmony_default_parameters_natives[] = {nullptr};
« no previous file with comments | « BUILD.gn ('k') | src/flag-definitions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698