Use a heap object for inputrec in gmx::Mdrunner::mdrunner().
commit0deeba4e67f162ba26a4fc974b6f2bcff9549b63
authorM. Eric Irrgang <mei2n@virginia.edu>
Thu, 27 Aug 2020 07:04:43 +0000 (27 07:04 +0000)
committerArtem Zhmurov <zhmurov@gmail.com>
Thu, 27 Aug 2020 07:04:43 +0000 (27 07:04 +0000)
tree9e05c5dcd8ac6352dc86089a61b78efcac409a6b
parent8601caf88e4fb4047c987830c14572ede4c994c6
Use a heap object for inputrec in gmx::Mdrunner::mdrunner().

Convert the inputrec pointer to a unique_ptr to combine the clean-up
behavior from both local variables. Remove the explicit inputrecInstance
local variable, converting to a heap object created through make_unique.
This allows the t_inputrec to be moved via its handle for more flexible
management, and allows the allocation to be moved closer to the
initialization.
src/gromacs/mdrun/runner.cpp