Skip to content

Commit

Permalink
src : elevate v8 namespaces
Browse files Browse the repository at this point in the history
Leverage `using` semantics for repeated usage of
v8 artifacts.

PR-URL: #28801
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
  • Loading branch information
HarshithaKP authored and targos committed Aug 2, 2019
1 parent 24b9d29 commit 3c30456
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/node_win32_etw_provider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

namespace node {

using v8::Isolate;
using v8::JitCodeEvent;
using v8::V8;

Expand Down Expand Up @@ -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);
}
Expand Down Expand Up @@ -199,7 +200,7 @@ void shutdown_etw() {
}

events_enabled = 0;
v8::Isolate::GetCurrent()->SetJitCodeEventHandler(
Isolate::GetCurrent()->SetJitCodeEventHandler(
v8::kJitCodeEventDefault,
nullptr);

Expand Down

0 comments on commit 3c30456

Please sign in to comment.