mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Apply coding style recommendations:
- space between keyword and bracket in 'for(..)', 'if(..)', 'while(..)'
This commit is contained in:
@ -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
|
||||
|
||||
|
||||
@ -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(
|
||||
|
||||
@ -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);
|
||||
|
||||
|
||||
@ -390,7 +390,7 @@ void Foam::boundaryMesh::markZone
|
||||
// Zones on all edges.
|
||||
labelList edgeZone(mesh().nEdges(), -1);
|
||||
|
||||
while(1)
|
||||
while (true)
|
||||
{
|
||||
changedEdges = faceToEdge
|
||||
(
|
||||
|
||||
@ -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
|
||||
|
||||
@ -35,13 +35,9 @@ License
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
|
||||
defineTypeNameAndDebug(setsToFaceZone, 0);
|
||||
|
||||
addToRunTimeSelectionTable(topoSetSource, setsToFaceZone, word);
|
||||
|
||||
addToRunTimeSelectionTable(topoSetSource, setsToFaceZone, istream);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user