ENH: use FatalErrorInLookup macros (#1362)

This commit is contained in:
Mark Olesen
2019-07-12 18:00:00 +02:00
committed by Andrew Heather
parent 1d86fc4f6b
commit fb09f56aba
290 changed files with 2634 additions and 2736 deletions

View File

@ -180,12 +180,12 @@ Foam::functionObjects::runTimePostPro::pathline::New
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown pathline type "
<< pathlineType << nl << nl
<< "Valid pathline types :" << endl
<< dictionaryConstructorTablePtr_->sortedToc()
<< exit(FatalError);
FatalErrorInLookup
(
"pathline",
pathlineType,
*dictionaryConstructorTablePtr_
) << exit(FatalError);
}
return autoPtr<pathline>(cstrIter()(parent, dict, colours));

View File

@ -143,12 +143,12 @@ Foam::functionObjects::runTimePostPro::pointData::New
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown pointData type "
<< pointDataType << nl << nl
<< "Valid pointData types :" << endl
<< dictionaryConstructorTablePtr_->sortedToc()
<< exit(FatalError);
FatalErrorInLookup
(
"pointData",
pointDataType,
*dictionaryConstructorTablePtr_
) << exit(FatalError);
}
return autoPtr<pointData>(cstrIter()(parent, dict, colours));

View File

@ -256,12 +256,12 @@ Foam::functionObjects::runTimePostPro::surface::New
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown surface type "
<< surfaceType << nl << nl
<< "Valid surface types :" << endl
<< dictionaryConstructorTablePtr_->sortedToc()
<< exit(FatalError);
FatalErrorInLookup
(
"surface",
surfaceType,
*dictionaryConstructorTablePtr_
) << exit(FatalError);
}
return autoPtr<surface>(cstrIter()(parent, dict, colours));