Apply coding style recommendations:

- space between keyword and bracket in 'for(..)', 'if(..)', 'while(..)'
This commit is contained in:
Mark Olesen
2009-11-30 08:55:03 +01:00
parent 6bdb7fb7b5
commit 909e6b27e4
148 changed files with 343 additions and 342 deletions

View File

@ -1404,7 +1404,11 @@ int main(int argc, char *argv[])
//it will be put in a default wall boundary
//internal boundaries are simply ignored
if(patchTypes[patchI] != "internal" && !pShapeMesh.isInternalFace(meshFaces[0]))
if
(
patchTypes[patchI] != "internal"
&& !pShapeMesh.isInternalFace(meshFaces[0])
)
{
//first face is external and has valid non-internal type

View File

@ -10,11 +10,12 @@
*** General
+ 80 character lines max
+ The body of control statements (eg, if, else, while, etc).
always delineated with brace brackets
+ Use spaces for indentation, not tab characters.
+ The normal indentation is 4 spaces per logical level.
+ Use spaces for indentation, not tab characters.
+ Avoid trailing whitespace.
+ The body of control statements (eg, if, else, while, etc).
always delineated with brace brackets. A possible exception can be
made with 'break' or 'continue' as part of a control structure.
+ stream output
=<<= is always four characters after the start of the stream,
@ -152,7 +153,7 @@
: code;
:}
*** =for= Loops
*** =for= and =while= Loops
:for (i = 0; i < maxI; i++)
:{
: code;
@ -180,7 +181,7 @@
Note that when indexing through iterators, it is often slightly more
efficient to use the pre-increment form. Eg, =++iter= instead of =iter++=
*** =forAll= loops
*** =forAll= , =forAllIter=, etc. loops
like =for= loops, but
:forAll(

View File

@ -114,7 +114,7 @@ void Foam::patchZones::markZone(label faceI)
// Zones on all edges.
labelList edgeZone(pp_.nEdges(), -1);
while(1)
while (true)
{
changedEdges = faceToEdge(changedFaces, edgeZone);

View File

@ -390,7 +390,7 @@ void Foam::boundaryMesh::markZone
// Zones on all edges.
labelList edgeZone(mesh().nEdges(), -1);
while(1)
while (true)
{
changedEdges = faceToEdge
(

View File

@ -142,7 +142,7 @@ void parcel::setRelaxationTimes
if (liquidCore_> 0.5)
{
// no drag for parcels in the liquid core..
// no drag for parcels in the liquid core.
tauMomentum = GREAT;
}
else

View File

@ -35,13 +35,9 @@ License
namespace Foam
{
defineTypeNameAndDebug(setsToFaceZone, 0);
addToRunTimeSelectionTable(topoSetSource, setsToFaceZone, word);
addToRunTimeSelectionTable(topoSetSource, setsToFaceZone, istream);
}