Remove misleading const qualifier for inputrec in expanded ensemble
authorPascal Merz <pascal.merz@me.com>
Wed, 6 Jan 2021 15:30:16 +0000 (15:30 +0000)
committerAndrey Alekseenko <al42and@gmail.com>
Wed, 6 Jan 2021 15:30:16 +0000 (15:30 +0000)
The expanded ensemble functionality took a const pointer to the
inputrec, but might change its references temperature. This is (at the
very least) misleading, so removed the const qualifier.

Refs #3854

src/gromacs/mdlib/expanded.cpp
src/gromacs/mdlib/expanded.h

index 15b886374513ab844f73840bd0734d5fb66e5b3e..bdac063a161d20d127f5f82dee67b156d22b3d6e 100644 (file)
@@ -2,7 +2,7 @@
  * This file is part of the GROMACS molecular simulation package.
  *
  * Copyright (c) 2012-2018, 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.
@@ -1203,7 +1203,7 @@ void PrintFreeEnergyInfoToFile(FILE*               outfile,
 }
 
 int ExpandedEnsembleDynamics(FILE*                 log,
-                             const t_inputrec*     ir,
+                             t_inputrec*           ir,
                              const gmx_enerdata_t* enerd,
                              t_state*              state,
                              t_extmass*            MassQ,
index 6f6bec9804e6b71c5d4d6e872c0c7dc540b5e8c8..289d0b9f46572ae1486c535fa058d2eeb8e1ca72 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * This file is part of the GROMACS molecular simulation package.
  *
- * Copyright (c) 2017,2018,2019, by the GROMACS development team, led by
+ * Copyright (c) 2017,2018,2019,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.
@@ -55,7 +55,7 @@ void init_npt_masses(const t_inputrec* ir, t_state* state, t_extmass* MassQ, gmx
 void init_expanded_ensemble(gmx_bool bStateFromCP, const t_inputrec* ir, df_history_t* dfhist);
 
 int ExpandedEnsembleDynamics(FILE*                 log,
-                             const t_inputrec*     ir,
+                             t_inputrec*           ir,
                              const gmx_enerdata_t* enerd,
                              t_state*              state,
                              t_extmass*            MassQ,