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); |
} |