STYLE: use auto + cfind for constructor tables

This commit is contained in:
Mark Olesen
2018-07-19 15:55:08 +02:00
parent cdcbcf4c78
commit 34a7ea5da7
10 changed files with 28 additions and 33 deletions

View File

@ -49,10 +49,9 @@ Foam::autoPtr<Foam::engineTime> Foam::engineTime::New
Info<< "Selecting engine type " << engineType << endl;
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(engineType);
auto cstrIter = dictionaryConstructorTablePtr_->cfind(engineType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown engine type "