From 168c808d5c87a04693cfc6ad66fe3ea22f8dfdef Mon Sep 17 00:00:00 2001 From: Ole Hansen <ole@jlab.org> Date: Thu, 12 Nov 2020 21:20:40 -0500 Subject: [PATCH] Fix compilation warnings from Apple Clang 12 --- DDCond/src/ConditionsRepository.cpp | 2 +- DDCore/src/GeometryTreeDump.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DDCond/src/ConditionsRepository.cpp b/DDCond/src/ConditionsRepository.cpp index 3b1cc56c4..f63a53c40 100644 --- a/DDCond/src/ConditionsRepository.cpp +++ b/DDCond/src/ConditionsRepository.cpp @@ -211,7 +211,7 @@ int ConditionsRepository::save(ConditionsManager manager, const string& output) for( const auto& cp : pool->elements ) { RangeConditions rc; cp.second->select_all(rc); - for( const auto cond : rc ) + for( const auto& cond : rc ) all[cond.key()] = cond; } } diff --git a/DDCore/src/GeometryTreeDump.cpp b/DDCore/src/GeometryTreeDump.cpp index bef918f13..bb2fa7733 100644 --- a/DDCore/src/GeometryTreeDump.cpp +++ b/DDCore/src/GeometryTreeDump.cpp @@ -190,7 +190,7 @@ void* GeometryTreeDump::handleSolid(const string& name, const TGeoShape* shape) /// Dump structure information in GDML format to output stream void GeometryTreeDump::handleStructure(const std::set<Volume>& volset) const { m_output << "\t<structure>" << endl; - for (const auto vol : volset) + for (const auto& vol : volset) handleVolume(vol->GetName(), vol); m_output << "\t</structure>" << endl; } -- GitLab