From ea655191d3df2b5ae62a66e5071cd151b1919c92 Mon Sep 17 00:00:00 2001
From: Shubham Urkade
Date: Sat, 17 Nov 2018 17:49:53 +0530
Subject: [PATCH] src: elevate repeated use of v8 namespaced type
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
PR-URL: https://github.com/nodejs/node/pull/24427
Reviewed-By: Michaƫl Zasso
Reviewed-By: Refael Ackermann
Reviewed-By: Anna Henningsen
Reviewed-By: Colin Ihrig
Reviewed-By: Gireesh Punathil
---
src/inspector_agent.cc | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/src/inspector_agent.cc b/src/inspector_agent.cc
index e0ee24a7f0c215..5e53201c42d5c2 100644
--- a/src/inspector_agent.cc
+++ b/src/inspector_agent.cc
@@ -37,6 +37,7 @@ using v8::Function;
using v8::HandleScope;
using v8::Isolate;
using v8::Local;
+using v8::Message;
using v8::Object;
using v8::String;
using v8::Value;
@@ -362,7 +363,7 @@ class SameThreadInspectorSession : public InspectorSession {
};
void NotifyClusterWorkersDebugEnabled(Environment* env) {
- v8::Isolate* isolate = env->isolate();
+ Isolate* isolate = env->isolate();
HandleScope handle_scope(isolate);
auto context = env->context();
@@ -512,7 +513,7 @@ class NodeInspectorClient : public V8InspectorClient {
}
}
- void FatalException(Local error, Local message) {
+ void FatalException(Local error, Local message) {
Isolate* isolate = env_->isolate();
Local context = env_->context();
@@ -762,7 +763,7 @@ void Agent::WaitForDisconnect() {
}
}
-void Agent::FatalException(Local error, Local message) {
+void Agent::FatalException(Local error, Local message) {
if (!IsListening())
return;
client_->FatalException(error, message);
@@ -774,8 +775,8 @@ void Agent::PauseOnNextJavascriptStatement(const std::string& reason) {
}
void Agent::RegisterAsyncHook(Isolate* isolate,
- v8::Local enable_function,
- v8::Local disable_function) {
+ Local enable_function,
+ Local disable_function) {
enable_async_hook_function_.Reset(isolate, enable_function);
disable_async_hook_function_.Reset(isolate, disable_function);
if (pending_enable_async_hook_) {
@@ -850,7 +851,7 @@ void Agent::RequestIoThreadStart() {
// continuous JS code) and to wake up libuv thread (in case Node is waiting
// for IO events)
uv_async_send(&start_io_thread_async);
- v8::Isolate* isolate = parent_env_->isolate();
+ Isolate* isolate = parent_env_->isolate();
v8::Platform* platform = parent_env_->isolate_data()->platform();
platform->CallOnForegroundThread(isolate, new StartIoTask(this));
isolate->RequestInterrupt(StartIoInterrupt, this);