From ff542972f677c9d5b4f604da605d2c7610a820ad Mon Sep 17 00:00:00 2001 From: yangguo Date: Wed, 20 Jul 2016 01:50:32 -0700 Subject: [PATCH] [debugger] remove deprecated api functions. Review-Url: https://codereview.chromium.org/2162503002 Cr-Commit-Position: refs/heads/master@{#37892} --- include/v8-debug.h | 14 -------------- src/api.cc | 32 -------------------------------- 2 files changed, 46 deletions(-) diff --git a/include/v8-debug.h b/include/v8-debug.h index 6520cbe0cd..6385a31d85 100644 --- a/include/v8-debug.h +++ b/include/v8-debug.h @@ -157,9 +157,6 @@ class V8_EXPORT Debug { static bool SetDebugEventListener(Isolate* isolate, EventCallback that, Local data = Local()); - V8_DEPRECATED("Use version with an Isolate", - static bool SetDebugEventListener( - EventCallback that, Local data = Local())); // Schedule a debugger break to happen when JavaScript code is run // in the given isolate. @@ -174,8 +171,6 @@ class V8_EXPORT Debug { // Message based interface. The message protocol is JSON. static void SetMessageHandler(Isolate* isolate, MessageHandler handler); - V8_DEPRECATED("Use version with an Isolate", - static void SetMessageHandler(MessageHandler handler)); static void SendCommand(Isolate* isolate, const uint16_t* command, int length, @@ -199,9 +194,6 @@ class V8_EXPORT Debug { * } * \endcode */ - static V8_DEPRECATED("Use maybe version", - Local Call(v8::Local fun, - Local data = Local())); // TODO(dcarney): data arg should be a MaybeLocal static MaybeLocal Call(Local context, v8::Local fun, @@ -210,8 +202,6 @@ class V8_EXPORT Debug { /** * Returns a mirror object for the given object. */ - static V8_DEPRECATED("Use maybe version", - Local GetMirror(v8::Local obj)); static MaybeLocal GetMirror(Local context, v8::Local obj); @@ -247,8 +237,6 @@ class V8_EXPORT Debug { * of this method. */ static void ProcessDebugMessages(Isolate* isolate); - V8_DEPRECATED("Use version with an Isolate", - static void ProcessDebugMessages()); /** * Debugger is running in its own context which is entered while debugger @@ -258,8 +246,6 @@ class V8_EXPORT Debug { * least one DebugEventListener or MessageHandler is set. */ static Local GetDebugContext(Isolate* isolate); - V8_DEPRECATED("Use version with an Isolate", - static Local GetDebugContext()); /** * While in the debug context, this method returns the top-most non-debug diff --git a/src/api.cc b/src/api.cc index 89afa3e4af..553cf485d4 100644 --- a/src/api.cc +++ b/src/api.cc @@ -8245,12 +8245,6 @@ bool Debug::SetDebugEventListener(Isolate* isolate, EventCallback that, } -bool Debug::SetDebugEventListener(EventCallback that, Local data) { - return SetDebugEventListener( - reinterpret_cast(i::Isolate::Current()), that, data); -} - - void Debug::DebugBreak(Isolate* isolate) { reinterpret_cast(isolate)->stack_guard()->RequestDebugBreak(); } @@ -8276,11 +8270,6 @@ void Debug::SetMessageHandler(Isolate* isolate, } -void Debug::SetMessageHandler(v8::Debug::MessageHandler handler) { - SetMessageHandler(reinterpret_cast(i::Isolate::Current()), handler); -} - - void Debug::SendCommand(Isolate* isolate, const uint16_t* command, int length, @@ -8310,13 +8299,6 @@ MaybeLocal Debug::Call(Local context, } -Local Debug::Call(v8::Local fun, - v8::Local data) { - auto context = ContextFromHeapObject(Utils::OpenHandle(*fun)); - RETURN_TO_LOCAL_UNCHECKED(Call(context, fun, data), Value); -} - - MaybeLocal Debug::GetMirror(Local context, v8::Local obj) { PREPARE_FOR_EXECUTION(context, Debug, GetMirror, Value); @@ -8338,21 +8320,11 @@ MaybeLocal Debug::GetMirror(Local context, } -Local Debug::GetMirror(v8::Local obj) { - RETURN_TO_LOCAL_UNCHECKED(GetMirror(Local(), obj), Value); -} - - void Debug::ProcessDebugMessages(Isolate* isolate) { reinterpret_cast(isolate)->debug()->ProcessDebugMessages(true); } -void Debug::ProcessDebugMessages() { - ProcessDebugMessages(reinterpret_cast(i::Isolate::Current())); -} - - Local Debug::GetDebugContext(Isolate* isolate) { i::Isolate* i_isolate = reinterpret_cast(isolate); ENTER_V8(i_isolate); @@ -8360,10 +8332,6 @@ Local Debug::GetDebugContext(Isolate* isolate) { } -Local Debug::GetDebugContext() { - return GetDebugContext(reinterpret_cast(i::Isolate::Current())); -} - MaybeLocal Debug::GetDebuggedContext(Isolate* isolate) { i::Isolate* i_isolate = reinterpret_cast(isolate); ENTER_V8(i_isolate);