Resolve warning messages generated by Gcc-11 and Clang-12

This commit is contained in:
Will Bainbridge
2021-07-15 09:51:16 +01:00
parent 25d274736f
commit d83c873f93
5 changed files with 13 additions and 16 deletions

View File

@ -1025,12 +1025,9 @@ Foam::dictionary Foam::dictionary::subOrEmptyDict
<< "keyword " << keyword << " is undefined in dictionary " << "keyword " << keyword << " is undefined in dictionary "
<< name() << name()
<< exit(FatalIOError); << exit(FatalIOError);
return entryPtr->dict();
}
else
{
return dictionary(*this, dictionary(name() + '/' + keyword));
} }
return dictionary(*this, dictionary(name() + '/' + keyword));
} }
else else
{ {

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org \\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2016-2018 OpenFOAM Foundation \\ / A nd | Copyright (C) 2016-2021 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -35,7 +35,7 @@ const char* const Foam::spatialTensor::vsType::componentNames[] =
{ {
"Exx", "Exy", "Exz", "Erxx", "Erxy", "Erxz", "Exx", "Exy", "Exz", "Erxx", "Erxy", "Erxz",
"Eyx", "Eyy", "Eyz", "Eryx", "Eryy", "Eryz", "Eyx", "Eyy", "Eyz", "Eryx", "Eryy", "Eryz",
"Ezx", "Ezy", "Ezz", "Erzx", "Erzy", "Erzz" "Ezx", "Ezy", "Ezz", "Erzx", "Erzy", "Erzz",
"Erxx", "Erxy", "Erxz", "Exx", "Exy", "Exz", "Erxx", "Erxy", "Erxz", "Exx", "Exy", "Exz",
"Eryx", "Eryy", "Eryz", "Eyx", "Eyy", "Eyz", "Eryx", "Eryy", "Eryz", "Eyx", "Eyy", "Eyz",

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org \\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2011-2019 OpenFOAM Foundation \\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -55,10 +55,10 @@ bool Foam::fileFormats::STARCDCore::readHeader
string line; string line;
is.getLine(line); is.getLine(line);
IStringStream(line)() >> header; (IStringStream(line)()) >> header;
is.getLine(line); is.getLine(line);
IStringStream(line)() >> majorVersion; (IStringStream(line)()) >> majorVersion;
// add other checks ... // add other checks ...
if (header != signature) if (header != signature)

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org \\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation \\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -189,7 +189,7 @@ void Foam::timeVaryingMappedFvPatchField<Type>::checkTable()
} }
else else
{ {
IFstream(valsFile)() >> vals; (IFstream(valsFile)()) >> vals;
} }
if (vals.size() != mapperPtr_().sourceSize()) if (vals.size() != mapperPtr_().sourceSize())
@ -243,7 +243,7 @@ void Foam::timeVaryingMappedFvPatchField<Type>::checkTable()
} }
else else
{ {
IFstream(valsFile)() >> vals; (IFstream(valsFile)()) >> vals;
} }
if (vals.size() != mapperPtr_().sourceSize()) if (vals.size() != mapperPtr_().sourceSize())

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org \\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2012-2020 OpenFOAM Foundation \\ / A nd | Copyright (C) 2012-2021 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -381,7 +381,7 @@ void Foam::timeVaryingMappedFixedValuePointPatchField<Type>::checkTable()
} }
else else
{ {
IFstream(valsFile)() >> vals; (IFstream(valsFile)()) >> vals;
} }
if (vals.size() != mapperPtr_().sourceSize()) if (vals.size() != mapperPtr_().sourceSize())
@ -441,7 +441,7 @@ void Foam::timeVaryingMappedFixedValuePointPatchField<Type>::checkTable()
} }
else else
{ {
IFstream(valsFile)() >> vals; (IFstream(valsFile)()) >> vals;
} }
if (vals.size() != mapperPtr_().sourceSize()) if (vals.size() != mapperPtr_().sourceSize())