STYLE: use forAllIter, forAllConstIter instead of long-hand version

STYLE: use 'forAll(' NOT 'forAll (', as per coding guide
This commit is contained in:
Mark Olesen
2010-04-12 11:18:38 +02:00
parent 0f58ac5a9b
commit a50f01b079
220 changed files with 1144 additions and 1898 deletions

View File

@ -47,19 +47,13 @@ int USERD_get_part_coords
}
else if (part_number == nPatches+2)
{
label indx = 1;
for
(
Cloud<passiveParticle>::iterator elmnt = sprayPtr->begin();
elmnt != sprayPtr->end();
++elmnt
)
forAllConstIter(Cloud<passiveParticle>, *sprayPtr, iter)
{
coord_array[0][indx] = (float)elmnt().position().x();
coord_array[1][indx] = (float)elmnt().position().y();
coord_array[2][indx] = (float)elmnt().position().z();
coord_array[0][indx] = (float)iter().position().x();
coord_array[1][indx] = (float)iter().position().y();
coord_array[2][indx] = (float)iter().position().z();
indx++;
}

View File

@ -17,7 +17,7 @@ int USERD_get_part_node_ids
nodeid_array[indx] = indx + 1;
}
}
else if (part_number < nPatches+2)
else if (part_number < nPatches+2)
{
label patchi = part_number-2;
@ -32,18 +32,14 @@ int USERD_get_part_node_ids
}
}
else if (part_number == nPatches+2)
else if (part_number == nPatches+2)
{
label indx = 0;
for
(
Cloud<passiveParticle>::iterator elmnt = sprayPtr->begin();
elmnt != sprayPtr->end();
++elmnt
)
forAllConstIter(Cloud<passiveParticle>, *sprayPtr, iter)
{
nodeid_array[indx] = indx + 1;
indx++;
nodeid_array[indx] = indx + 1;
indx++;
}
}
else