From 3c30456f6a942d078039619ab641c99ec9ff92f6 Mon Sep 17 00:00:00 2001 From: Harshitha KP Date: Mon, 22 Jul 2019 06:04:42 -0400 Subject: [PATCH] src : elevate v8 namespaces MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Leverage `using` semantics for repeated usage of v8 artifacts. PR-URL: https://github.com/nodejs/node/pull/28801 Reviewed-By: Anna Henningsen Reviewed-By: Michaƫl Zasso Reviewed-By: Rich Trott Reviewed-By: Colin Ihrig Reviewed-By: Gireesh Punathil --- src/node_win32_etw_provider.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/node_win32_etw_provider.cc b/src/node_win32_etw_provider.cc index fe9c510221b417..7b0c696a9c8882 100644 --- a/src/node_win32_etw_provider.cc +++ b/src/node_win32_etw_provider.cc @@ -26,6 +26,7 @@ namespace node { +using v8::Isolate; using v8::JitCodeEvent; using v8::V8; @@ -127,11 +128,11 @@ void CodeAddressNotification(const JitCodeEvent* jevent) { void etw_events_change_async(uv_async_t* handle) { if (events_enabled > 0) { NODE_V8SYMBOL_RESET(); - v8::Isolate::GetCurrent()->SetJitCodeEventHandler( + Isolate::GetCurrent()->SetJitCodeEventHandler( v8::kJitCodeEventEnumExisting, CodeAddressNotification); } else { - v8::Isolate::GetCurrent()->SetJitCodeEventHandler( + Isolate::GetCurrent()->SetJitCodeEventHandler( v8::kJitCodeEventDefault, nullptr); } @@ -199,7 +200,7 @@ void shutdown_etw() { } events_enabled = 0; - v8::Isolate::GetCurrent()->SetJitCodeEventHandler( + Isolate::GetCurrent()->SetJitCodeEventHandler( v8::kJitCodeEventDefault, nullptr);