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

Unified Diff: src/extensions/gc-extension.cc

Issue 1162363005: Remove usage of to-be-deprecated APIs from v8 core (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 5 years, 7 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/extensions/externalize-string-extension.cc ('k') | src/extensions/statistics-extension.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/extensions/gc-extension.cc
diff --git a/src/extensions/gc-extension.cc b/src/extensions/gc-extension.cc
index fbe40a6195397be966c60dfadebd571649162377..f4026f57dcb477ac3033122d90ef1c719d71579f 100644
--- a/src/extensions/gc-extension.cc
+++ b/src/extensions/gc-extension.cc
@@ -19,8 +19,11 @@ v8::Handle<v8::FunctionTemplate> GCExtension::GetNativeFunctionTemplate(
void GCExtension::GC(const v8::FunctionCallbackInfo<v8::Value>& args) {
args.GetIsolate()->RequestGarbageCollectionForTesting(
- args[0]->BooleanValue() ? v8::Isolate::kMinorGarbageCollection
- : v8::Isolate::kFullGarbageCollection);
+ args[0]
+ ->BooleanValue(args.GetIsolate()->GetCurrentContext())
+ .FromMaybe(false)
+ ? v8::Isolate::kMinorGarbageCollection
+ : v8::Isolate::kFullGarbageCollection);
}
} // namespace internal
« no previous file with comments | « src/extensions/externalize-string-extension.cc ('k') | src/extensions/statistics-extension.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698