mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: check autoPtr as plain bool instead of valid()
- cleaner code, more similarity with unique_ptr
Now
if (ptr)
if (!ptr)
instead
if (ptr.valid())
if (!ptr.valid())
This commit is contained in:
@ -137,9 +137,9 @@ label mergePatchFaces
|
||||
// Faces in error.
|
||||
labelHashSet errorFaces;
|
||||
|
||||
if (qualDictPtr.valid())
|
||||
if (qualDictPtr)
|
||||
{
|
||||
motionSmoother::checkMesh(false, mesh, qualDictPtr(), errorFaces);
|
||||
motionSmoother::checkMesh(false, mesh, *qualDictPtr, errorFaces);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -440,7 +440,7 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
|
||||
// Merge points on straight edges and remove unused points
|
||||
if (qualDict.valid())
|
||||
if (qualDict)
|
||||
{
|
||||
Info<< "Merging all 'loose' points on surface edges, "
|
||||
<< "regardless of the angle they make." << endl;
|
||||
|
||||
Reference in New Issue
Block a user