diff --git a/src/api/callback.cc b/src/api/callback.cc index 6ca7cda3a5d3f1..a7070c2516f1ad 100644 --- a/src/api/callback.cc +++ b/src/api/callback.cc @@ -7,7 +7,6 @@ namespace node { using v8::Context; -using v8::EscapableHandleScope; using v8::Function; using v8::HandleScope; using v8::Isolate; @@ -362,39 +361,4 @@ MaybeLocal MakeSyncCallback(Isolate* isolate, return ret; } -// Legacy MakeCallback()s - -Local MakeCallback(Isolate* isolate, - Local recv, - const char* method, - int argc, - Local* argv) { - EscapableHandleScope handle_scope(isolate); - return handle_scope.Escape( - MakeCallback(isolate, recv, method, argc, argv, {0, 0}) - .FromMaybe(Local())); -} - -Local MakeCallback(Isolate* isolate, - Local recv, - Local symbol, - int argc, - Local* argv) { - EscapableHandleScope handle_scope(isolate); - return handle_scope.Escape( - MakeCallback(isolate, recv, symbol, argc, argv, {0, 0}) - .FromMaybe(Local())); -} - -Local MakeCallback(Isolate* isolate, - Local recv, - Local callback, - int argc, - Local* argv) { - EscapableHandleScope handle_scope(isolate); - return handle_scope.Escape( - MakeCallback(isolate, recv, callback, argc, argv, {0, 0}) - .FromMaybe(Local())); -} - } // namespace node diff --git a/src/node.h b/src/node.h index f773096c959b59..82ed4eb1258a83 100644 --- a/src/node.h +++ b/src/node.h @@ -175,35 +175,6 @@ NODE_DEPRECATED("Use UVException(isolate, ...)", path); }) -/* - * These methods need to be called in a HandleScope. - * - * It is preferred that you use the `MakeCallback` overloads taking - * `async_context` arguments. - */ - -NODE_DEPRECATED("Use MakeCallback(..., async_context)", - NODE_EXTERN v8::Local MakeCallback( - v8::Isolate* isolate, - v8::Local recv, - const char* method, - int argc, - v8::Local* argv)); -NODE_DEPRECATED("Use MakeCallback(..., async_context)", - NODE_EXTERN v8::Local MakeCallback( - v8::Isolate* isolate, - v8::Local recv, - v8::Local symbol, - int argc, - v8::Local* argv)); -NODE_DEPRECATED("Use MakeCallback(..., async_context)", - NODE_EXTERN v8::Local MakeCallback( - v8::Isolate* isolate, - v8::Local recv, - v8::Local callback, - int argc, - v8::Local* argv)); - } // namespace node #include