No need to capture proxy by reference.
Change-Id: I2a75a3395a7c7d8164bb308e5f2cdde03f4aeb55
const char *format = get_hconf_format(v != nullptr);
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
int i = atomP.globalAtomNumber();
int residueNumber = atomP.residueNumber();
snew(*x, mtop->natoms);
nq = 0;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
boltz = BOLTZ*tempi;
ekin = 0.0;
nrdf = 0;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
static void check_vel(gmx_mtop_t *mtop, rvec v[])
{
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
int nshells = 0;
char warn_buf[STRLEN];
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
if (local.ptype == eptShell ||
real *mass;
snew(mass, state->natoms);
- for (const AtomProxy &atomP : AtomRange(*sys))
+ for (const AtomProxy atomP : AtomRange(*sys))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
rvec *v)
{
double sum_mv2 = 0;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
}
snew(nrdf2, natoms);
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
{
clear_rvec(acc);
snew(mgrp, sys->groups.grps[egcACC].nr);
- for (const AtomProxy &atomP : AtomRange(*sys))
+ for (const AtomProxy atomP : AtomRange(*sys))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
rvec com = { 0, 0, 0 };
double mtot = 0.0;
int j = 0;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
std::vector<int> qmmmAtoms;
for (int i = 0; i < numQmmmGroups; i++)
{
- for (const AtomProxy &atomP : AtomRange(mtop))
+ for (const AtomProxy atomP : AtomRange(mtop))
{
int index = atomP.globalAtomNumber();
if (getGroupType(groups, egcQMMM, index) == i)
snew(shell_index, mtop->natoms);
nshell = 0;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
if (ngacc > 0)
{
const gmx_groups_t &groups = mtop->groups;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int i = atomP.globalAtomNumber();
{
std::vector<real> qA(mtop.natoms);
std::vector<real> qB(mtop.natoms);
- for (const AtomProxy &atomP : AtomRange(mtop))
+ for (const AtomProxy atomP : AtomRange(mtop))
{
const t_atom &local = atomP.atom();
int index = atomP.globalAtomNumber();
{
std::vector<int> atom_index;
- for (const AtomProxy &atomP : AtomRange(*mtop))
+ for (const AtomProxy atomP : AtomRange(*mtop))
{
const t_atom &local = atomP.atom();
int index = atomP.globalAtomNumber();
gmx_mtop_t mtop;
createBasicTop(&mtop);
int count = 0;
- for (const AtomProxy &atomP : AtomRange(mtop))
+ for (const AtomProxy atomP : AtomRange(mtop))
{
EXPECT_EQ(atomP.globalAtomNumber(), count);
++count;