From b5e2cb228eda143bbe11ea814d37cd4bbc23ea2a Mon Sep 17 00:00:00 2001 From: scott snyder <snyder@bnl.gov> Date: Wed, 6 Jan 2021 15:44:05 +0100 Subject: [PATCH] TrigConfIO: Fix clang warnings. Avoid spurious copies in range-for. --- .../TrigConfiguration/TrigConfIO/src/JsonFileWriterHLT.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterHLT.cxx b/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterHLT.cxx index 4256e6f3b84..930408ee064 100644 --- a/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterHLT.cxx +++ b/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterHLT.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration */ #include "TrigConfIO/JsonFileWriterHLT.h" @@ -36,12 +36,12 @@ TrigConf::JsonFileWriterHLT::writeJsonFile(const std::string & filename, const H } json sequencers({}); - for ( const auto [seqName, algsList]: menu.sequencers() ) { + for ( const auto& [seqName, algsList]: menu.sequencers() ) { json jSeq( algsList ); sequencers[seqName] = jSeq; } json streams({}); - for ( const auto stream: menu.streams() ) { + for ( const auto& stream: menu.streams() ) { json jStream({}); jStream["name"] = stream["name"]; jStream["type"] = stream["type"]; -- GitLab