STYLE: use brace constructors for Foam::zero and Foam::one

- makes it clearer that these are constructors and not function calls
This commit is contained in:
Mark Olesen
2020-10-24 13:32:44 +02:00
parent 98d05fa80a
commit 07bbae0c55
35 changed files with 71 additions and 71 deletions

View File

@ -446,7 +446,7 @@ int main(int argc, char *argv[])
// Default exposed patch id
labelList exposedPatchIDs(one(), -1);
labelList exposedPatchIDs(one{}, -1);
if (args.found("patches"))
{

View File

@ -95,7 +95,7 @@ Description
auto writer = autoPtr<vtk::patchWriter>::New
(
meshProxy.mesh(),
labelList(one(), pp.index()),
labelList(one{}, pp.index()),
writeOpts,
nearCellValue,
(

View File

@ -195,7 +195,7 @@ Description
auto writer = autoPtr<vtk::patchWriter>::New
(
meshProxy.mesh(),
labelList(one(), pp.index()),
labelList(one{}, pp.index()),
writeOpts,
nearCellValue,
// Output patch: "boundary"/name

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2020 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -571,7 +571,7 @@ Foam::meshedSurface Foam::PDRobstacle::surface() const
// pts += obs.pt;
faceList fcs(one(), face(identity(4)));
faceList fcs(one{}, face(identity(4)));
surf.transfer(pts, fcs);

View File

@ -122,7 +122,7 @@ HashTable<wordList> extractPatchGroups(const dictionary& boundaryDict)
}
else
{
groupToPatch.insert(groupName, wordList(one(), patchName));
groupToPatch.insert(groupName, wordList(one{}, patchName));
}
}
}