STYLE: two-parameter Foam::name replaced by word::printf (issue #724)

- reduces some ambiguity and clarifies the expected output and
  behaviour.

STYLE: reduce some automatic conversions of char to string
This commit is contained in:
Mark Olesen
2018-02-08 12:00:54 +01:00
parent fa8d972796
commit 806b668418
36 changed files with 233 additions and 251 deletions

View File

@ -312,7 +312,7 @@ bool Foam::sampledTriSurfaceMesh::update(const meshSearch& meshSearcher)
patchi,
(
patches[patchi].name().empty()
? Foam::name("patch%d", patchi)
? word::printf("patch%d", patchi)
: patches[patchi].name()
)
);
@ -345,7 +345,7 @@ bool Foam::sampledTriSurfaceMesh::update(const meshSearch& meshSearcher)
zoneNames.set
(
regionid,
Foam::name("patch%d", regionid)
word::printf("patch%d", regionid)
);
}
@ -393,7 +393,7 @@ bool Foam::sampledTriSurfaceMesh::update(const meshSearch& meshSearcher)
}
if (name.empty())
{
name = ::Foam::name("patch%d", regionid);
name = word::printf("patch%d", regionid);
}
zoneLst[zoneI] = surfZone

View File

@ -306,7 +306,7 @@ bool Foam::discreteSurface::update(const meshSearch& meshSearcher)
patchi,
(
patches[patchi].name().empty()
? Foam::name("patch%d", patchi)
? word::printf("patch%d", patchi)
: patches[patchi].name()
)
);
@ -339,7 +339,7 @@ bool Foam::discreteSurface::update(const meshSearch& meshSearcher)
zoneNames.set
(
regionid,
Foam::name("patch%d", regionid)
word::printf("patch%d", regionid)
);
}
@ -387,7 +387,7 @@ bool Foam::discreteSurface::update(const meshSearch& meshSearcher)
}
if (name.empty())
{
name = ::Foam::name("patch%d", regionid);
name = word::printf("patch%d", regionid);
}
zoneLst[zoneI] = surfZone