diff --git a/src/env.cc b/src/env.cc index 833f4bac4066f5..e762715bfb5c39 100644 --- a/src/env.cc +++ b/src/env.cc @@ -610,7 +610,7 @@ IsolateData::~IsolateData() {} // Deprecated API, embedders should use v8::Object::Wrap() directly instead. void SetCppgcReference(Isolate* isolate, Local object, - void* wrappable) { + v8::Object::Wrappable* wrappable) { v8::Object::Wrap( isolate, object, wrappable); } diff --git a/src/node.h b/src/node.h index 830d6250415b9e..c3e37f6f6be3f1 100644 --- a/src/node.h +++ b/src/node.h @@ -1540,9 +1540,10 @@ void RegisterSignalHandler(int signal, // work with only Node.js versions with v8::Object::Wrap() should use that // instead. NODE_DEPRECATED("Use v8::Object::Wrap()", - NODE_EXTERN void SetCppgcReference(v8::Isolate* isolate, - v8::Local object, - void* wrappable)); + NODE_EXTERN void SetCppgcReference( + v8::Isolate* isolate, + v8::Local object, + v8::Object::Wrappable* wrappable)); } // namespace node diff --git a/test/addons/cppgc-object/binding.cc b/test/addons/cppgc-object/binding.cc index 7fc16a87b843ce..63fb1dbdc96d4f 100644 --- a/test/addons/cppgc-object/binding.cc +++ b/test/addons/cppgc-object/binding.cc @@ -8,7 +8,7 @@ #include #include -class CppGCed : public cppgc::GarbageCollected { +class CppGCed : public v8::Object::Wrappable { public: static uint16_t states[2]; static constexpr int kDestructCount = 0; diff --git a/test/cctest/test_cppgc.cc b/test/cctest/test_cppgc.cc index 21f981f9ab229f..5bbe6495bf0cb7 100644 --- a/test/cctest/test_cppgc.cc +++ b/test/cctest/test_cppgc.cc @@ -10,7 +10,7 @@ // This tests that Node.js can work with an existing CppHeap. // Mimic a class that does not know about Node.js. -class CppGCed : public cppgc::GarbageCollected { +class CppGCed : public v8::Object::Wrappable { public: static int kConstructCount; static int kDestructCount;