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

Unified Diff: src/api.cc

Issue 687003005: Introduce phantom weak handles in the API and use them internally for debug info (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 1 month 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 | « include/v8.h ('k') | src/compiler.cc » ('j') | src/global-handles.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index 5abd0eb5e52a52d6676a5fcf44fdee03a0643d61..c9231a31e75d2f637c8afd36904441d1cddd3548 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -490,10 +490,12 @@ i::Object** V8::CopyPersistent(i::Object** obj) {
}
-void V8::MakeWeak(i::Object** object,
- void* parameters,
- WeakCallback weak_callback) {
- i::GlobalHandles::MakeWeak(object, parameters, weak_callback);
+void V8::MakeWeak(i::Object** object, void* parameters,
+ WeakCallback weak_callback, V8::WeakHandleType weak_type) {
+ i::GlobalHandles::PhantomState phantom;
+ phantom = weak_type == V8::PhantomHandle ? i::GlobalHandles::Phantom
+ : i::GlobalHandles::Nonphantom;
+ i::GlobalHandles::MakeWeak(object, parameters, weak_callback, phantom);
}
« no previous file with comments | « include/v8.h ('k') | src/compiler.cc » ('j') | src/global-handles.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698