diff options
author | Anna Henningsen <anna@addaleax.net> | 2018-04-17 17:47:09 +0200 |
---|---|---|
committer | Anatoli Papirovski <apapirovski@mac.com> | 2018-04-22 11:23:29 +0200 |
commit | 1f3fbd43b7e73e16cb383bda36663517bf20540b (patch) | |
tree | 0fee58a54b78d56e04509ed4e135956997983bd5 | |
parent | aaea70693e0b186672c0912a2bea6a68f691d9f8 (diff) | |
download | android-node-v8-1f3fbd43b7e73e16cb383bda36663517bf20540b.tar.gz android-node-v8-1f3fbd43b7e73e16cb383bda36663517bf20540b.tar.bz2 android-node-v8-1f3fbd43b7e73e16cb383bda36663517bf20540b.zip |
src: remove `MarkIndependent()` calls
The method has been deprecated in upstream V8, with messaging
indicating that it is the default for handles to be independent
now anyway.
PR-URL: https://github.com/nodejs/node/pull/20108
Refs: https://github.com/v8/v8/commit/71ad48fb8f214e80518ba0419796e4c571351255
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
-rw-r--r-- | src/base_object-inl.h | 1 | ||||
-rw-r--r-- | src/node_api.cc | 2 | ||||
-rw-r--r-- | src/node_buffer.cc | 1 | ||||
-rw-r--r-- | src/node_contextify.cc | 1 | ||||
-rw-r--r-- | src/node_object_wrap.h | 1 |
5 files changed, 0 insertions, 6 deletions
diff --git a/src/base_object-inl.h b/src/base_object-inl.h index 51ef465996..5ff211f473 100644 --- a/src/base_object-inl.h +++ b/src/base_object-inl.h @@ -70,7 +70,6 @@ inline void BaseObject::MakeWeak(Type* ptr) { v8::Local<v8::Object> handle = object(); CHECK_GT(handle->InternalFieldCount(), 0); Wrap(handle, ptr); - persistent_handle_.MarkIndependent(); persistent_handle_.SetWeak<Type>(ptr, WeakCallback<Type>, v8::WeakCallbackType::kParameter); } diff --git a/src/node_api.cc b/src/node_api.cc index 3a02e5effa..ea7ddba77d 100644 --- a/src/node_api.cc +++ b/src/node_api.cc @@ -387,7 +387,6 @@ class Reference : private Finalizer { if (initial_refcount == 0) { _persistent.SetWeak( this, FinalizeCallback, v8::WeakCallbackType::kParameter); - _persistent.MarkIndependent(); } } @@ -431,7 +430,6 @@ class Reference : private Finalizer { if (--_refcount == 0) { _persistent.SetWeak( this, FinalizeCallback, v8::WeakCallbackType::kParameter); - _persistent.MarkIndependent(); } return _refcount; diff --git a/src/node_buffer.cc b/src/node_buffer.cc index b00886f5e6..38b473b8ce 100644 --- a/src/node_buffer.cc +++ b/src/node_buffer.cc @@ -144,7 +144,6 @@ CallbackInfo::CallbackInfo(Isolate* isolate, persistent_.SetWeak(this, WeakCallback, v8::WeakCallbackType::kParameter); persistent_.SetWrapperClassId(BUFFER_ID); - persistent_.MarkIndependent(); isolate->AdjustAmountOfExternalAllocatedMemory(sizeof(*this)); } diff --git a/src/node_contextify.cc b/src/node_contextify.cc index ce23576501..68251004d5 100644 --- a/src/node_contextify.cc +++ b/src/node_contextify.cc @@ -104,7 +104,6 @@ ContextifyContext::ContextifyContext( if (context_.IsEmpty()) return; context_.SetWeak(this, WeakCallback, v8::WeakCallbackType::kParameter); - context_.MarkIndependent(); } diff --git a/src/node_object_wrap.h b/src/node_object_wrap.h index 37c759fb89..b8ed2f9913 100644 --- a/src/node_object_wrap.h +++ b/src/node_object_wrap.h @@ -83,7 +83,6 @@ class ObjectWrap { inline void MakeWeak(void) { persistent().SetWeak(this, WeakCallback, v8::WeakCallbackType::kParameter); - persistent().MarkIndependent(); } /* Ref() marks the object as being attached to an event loop. |