From ca4ab4297355ac4b3ee12945d734aa880e981859 Mon Sep 17 00:00:00 2001 From: Dominik Gleich Date: Wed, 8 Mar 2017 11:13:49 +0100 Subject: [PATCH] Supress intentional unused variable warning in for loop. Reviewers: florijan, buda Reviewed By: buda Subscribers: pullbot Differential Revision: https://phabricator.memgraph.io/D101 --- tests/unit/graph_db_accessor.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/unit/graph_db_accessor.cpp b/tests/unit/graph_db_accessor.cpp index 00ba764fc..8145bccd8 100644 --- a/tests/unit/graph_db_accessor.cpp +++ b/tests/unit/graph_db_accessor.cpp @@ -9,14 +9,14 @@ size_t CountVertices(GraphDbAccessor &db_accessor) { size_t r_val = 0; - for (auto va : db_accessor.vertices()) r_val++; + for ([[gnu::unused]] auto va : db_accessor.vertices()) r_val++; return r_val; } size_t CountEdges(GraphDbAccessor &db_accessor) { size_t r_val = 0; - for (auto va : db_accessor.edges()) r_val++; + for ([[gnu::unused]] auto va : db_accessor.edges()) r_val++; return r_val; }