STYLE: avoid unrestricted dictionary lookup in conversion, sampling, surfMesh

- aids with detection of excess tokens (issue #762)

- deprecated dictionary::operator[] in favour of the lookup() method
  which offers more flexibilty and clarity of purpose.
  Additionally, the read<> and get<> forms should generally be used
  instead anyhow.
This commit is contained in:
Mark Olesen
2018-07-18 13:33:00 +02:00
parent 956abe3f38
commit a592ebc073
59 changed files with 158 additions and 262 deletions

View File

@ -325,8 +325,8 @@ Foam::shortestPathSet::shortestPathSet
)
:
sampledSet(name, mesh, searchEngine, dict),
insidePoints_(dict.lookup("insidePoints")),
outsidePoints_(dict.lookup("outsidePoints"))
insidePoints_(dict.get<pointField>("insidePoints")),
outsidePoints_(dict.get<pointField>("outsidePoints"))
{
genSamples(mesh);
}