clang-tidy-11 fixes for gmxpreprocess
[alexxy/gromacs.git] / src / gromacs / gmxpreprocess / gmxcpp.cpp
index 1a597a41012b539dfa6f4e9dffb2f2be68e11f3a..bde57d24434cb7766a6dd52788c9ff27e55acf08 100644 (file)
@@ -4,7 +4,7 @@
  * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
  * Copyright (c) 2001-2004, The GROMACS development team.
  * Copyright (c) 2013,2014,2015,2017,2018 by the GROMACS development team.
- * Copyright (c) 2019,2020, by the GROMACS development team, led by
+ * Copyright (c) 2019,2020,2021, by the GROMACS development team, led by
  * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
  * and including many others, as listed in the AUTHORS file in the
  * top-level source directory and at http://www.gromacs.org.
@@ -770,7 +770,7 @@ std::string checkAndWarnForUnusedDefines(const gmx_cpp& handle)
                 "The following macros were defined in the 'define' mdp field with the -D prefix, "
                 "but "
                 "were not used in the topology:\n";
-        for (auto& str : handle.unmatched_defines)
+        for (const auto& str : handle.unmatched_defines)
         {
             warning += ("    " + str + "\n");
         }