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

Unified Diff: src/bootstrapper.cc

Issue 567313003: RegExp: Add support for the ES6-proposed sticky flag (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add test of ^ behaviour in sticky regexp Created 6 years, 3 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 | « no previous file | src/compilation-cache.cc » ('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 dbf6e0e9c11d1288ca81e48af32ab9270dba3d20..bf31fa090b2820357d59fe0633d46d3db74ff3e4 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -1417,6 +1417,15 @@ void Genesis::InitializeExperimentalGlobal() {
native_context()->set_generator_object_prototype_map(
*generator_object_prototype_map);
}
+ v8::Isolate* external_isolate = reinterpret_cast<v8::Isolate*>(isolate());
+ v8::Local<v8::Boolean> flag = FLAG_harmony_regexps ?
+ v8::True(external_isolate) :
+ v8::False(external_isolate);
Yang 2014/09/17 07:16:14 Let's not unnecessarily use API handles. We can ju
Erik Corry 2014/09/17 17:06:19 Done.
+ Handle<JSBuiltinsObject> builtins(native_context()->builtins());
+ Runtime::DefineObjectProperty(builtins,
+ factory()->InternalizeOneByteString(
+ STATIC_CHAR_VECTOR("harmony_regexps")),
+ Utils::OpenHandle(*flag), NONE).Assert();
}
« no previous file with comments | « no previous file | src/compilation-cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698