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

Unified Diff: src/d8.cc

Issue 933863002: [strong] make --use-strong flag work in d8 (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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 | test/mjsunit/mjsunit.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/d8.cc
diff --git a/src/d8.cc b/src/d8.cc
index 953a37519e4ba4b784606d699e2a42c62bbc58c4..7fa6f8c42e68a2cfd9de7f955da93229b94d1283 100644
--- a/src/d8.cc
+++ b/src/d8.cc
@@ -838,7 +838,20 @@ void Shell::AddHistogramSample(void* histogram, int sample) {
}
+class NoUseStrongForUtilityScriptScope {
+ public:
+ NoUseStrongForUtilityScriptScope() : flag_(i::FLAG_use_strong) {
+ i::FLAG_use_strong = false;
+ }
+ ~NoUseStrongForUtilityScriptScope() { i::FLAG_use_strong = flag_; }
+
+ private:
+ bool flag_;
+};
+
+
void Shell::InstallUtilityScript(Isolate* isolate) {
+ NoUseStrongForUtilityScriptScope no_use_strong;
HandleScope scope(isolate);
// If we use the utility context, we have to set the security tokens so that
// utility, evaluation and debug context can all access each other.
« no previous file with comments | « no previous file | test/mjsunit/mjsunit.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698