From 3b3104341971cfd910d4da641610a710b2ee80ca Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Sun, 4 Feb 2018 06:32:24 +0100 Subject: [PATCH] test: suppress unused warning postmortem_metadata Currently the following warning is generated by when building the cctests: ../test/cctest/test_node_postmortem_metadata.cc:133:13: warning: unused variable 'it' [-Wunused-variable] for (auto it : *(*env)->req_wrap_queue()) {} ^ 1 warning generated. This commmit adds a cast to void to suppres the warning. --- test/cctest/test_node_postmortem_metadata.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/cctest/test_node_postmortem_metadata.cc b/test/cctest/test_node_postmortem_metadata.cc index 9ba6e15593a019..51ec94cc86f8c6 100644 --- a/test/cctest/test_node_postmortem_metadata.cc +++ b/test/cctest/test_node_postmortem_metadata.cc @@ -130,7 +130,7 @@ TEST_F(DebugSymbolsTest, ReqWrapList) { // NOTE (mmarchini): Workaround to fix failing tests on ARM64 machines with // older GCC. Should be removed once we upgrade the GCC version used on our // ARM64 CI machinies. - for (auto it : *(*env)->req_wrap_queue()) {} + for (auto it : *(*env)->req_wrap_queue()) { (void) it; } auto queue = reinterpret_cast((*env)->req_wrap_queue()); auto head = queue +