From 90d481ea45b0290b0562b5a09a273e6c27cae4fd Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Tue, 4 Dec 2018 05:17:48 +0100 Subject: [PATCH] src: remove unused env variables in node_util Currently the following compiler warnings are generated: ../src/node_util.cc:59:16: warning: unused variable 'env' [-Wunused-variable] Environment* env = Environment::GetCurrent(args); ^ ../src/node_util.cc:78:16: warning: unused variable 'env' [-Wunused-variable] Environment* env = Environment::GetCurrent(args); ^ 2 warnings generated. This commit removes the two unused variables. PR-URL: https://github.com/nodejs/node/pull/24820 Reviewed-By: Sam Roberts Reviewed-By: Richard Lau Reviewed-By: Colin Ihrig Reviewed-By: Jeremiah Senkpiel Reviewed-By: Luigi Pinca --- src/node_util.cc | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/node_util.cc b/src/node_util.cc index 4a426ddadb2a20..f6ebee895fe3bf 100644 --- a/src/node_util.cc +++ b/src/node_util.cc @@ -56,7 +56,6 @@ static void GetOwnNonIndexProperties( } static void GetPromiseDetails(const FunctionCallbackInfo& args) { - Environment* env = Environment::GetCurrent(args); // Return undefined if it's not a Promise. if (!args[0]->IsPromise()) return; @@ -75,7 +74,6 @@ static void GetPromiseDetails(const FunctionCallbackInfo& args) { } static void GetProxyDetails(const FunctionCallbackInfo& args) { - Environment* env = Environment::GetCurrent(args); // Return undefined if it's not a proxy. if (!args[0]->IsProxy()) return;