diff --git a/applications/solvers/combustion/PDRFoam/PDRModels/dragModels/PDRDragModel/PDRDragModel.H b/applications/solvers/combustion/PDRFoam/PDRModels/dragModels/PDRDragModel/PDRDragModel.H index 4cf9422804..e7bd21a628 100644 --- a/applications/solvers/combustion/PDRFoam/PDRModels/dragModels/PDRDragModel/PDRDragModel.H +++ b/applications/solvers/combustion/PDRFoam/PDRModels/dragModels/PDRDragModel/PDRDragModel.H @@ -155,6 +155,9 @@ public: //- Return the momentum drag turbulence generation rate virtual tmp Gk() const = 0; + //- Inherit read from regIOobject + using regIOobject::read; + //- Update properties from given dictionary virtual bool read(const dictionary& PDRProperties) = 0; diff --git a/applications/solvers/multiphase/multiphaseEulerFoam/multiphaseSystem/phaseModel/phaseModel.H b/applications/solvers/multiphase/multiphaseEulerFoam/multiphaseSystem/phaseModel/phaseModel.H index abaab320f6..54d6119e49 100644 --- a/applications/solvers/multiphase/multiphaseEulerFoam/multiphaseSystem/phaseModel/phaseModel.H +++ b/applications/solvers/multiphase/multiphaseEulerFoam/multiphaseSystem/phaseModel/phaseModel.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -211,6 +211,9 @@ public: //- Correct the phase properties void correct(); + //-Inherit read from volScalarField + using volScalarField::read; + //- Read base transportProperties dictionary bool read(const dictionary& phaseDict); }; diff --git a/applications/solvers/multiphase/multiphaseInterFoam/multiphaseMixture/phase/phase.H b/applications/solvers/multiphase/multiphaseInterFoam/multiphaseMixture/phase/phase.H index 74c0aaba83..91341fcf5c 100644 --- a/applications/solvers/multiphase/multiphaseInterFoam/multiphaseMixture/phase/phase.H +++ b/applications/solvers/multiphase/multiphaseInterFoam/multiphaseMixture/phase/phase.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -144,6 +144,9 @@ public: //- Correct the phase properties void correct(); + //-Inherit read from volScalarField + using volScalarField::read; + //- Read base transportProperties dictionary bool read(const dictionary& phaseDict); }; diff --git a/applications/utilities/mesh/conversion/gambitToFoam/gambitToFoam.L b/applications/utilities/mesh/conversion/gambitToFoam/gambitToFoam.L index ef3f3c3b2a..9f3f615dc6 100644 --- a/applications/utilities/mesh/conversion/gambitToFoam/gambitToFoam.L +++ b/applications/utilities/mesh/conversion/gambitToFoam/gambitToFoam.L @@ -186,7 +186,6 @@ mtype {space}"MTYPE:"{space} label curNumberOfNodes = 0; label curNumberOfCells = 0; label curGroupID = 0; - label nFlagsForStream = 0; label curBoundaryPatch = 0; label curPatchFace = 0; %} @@ -478,7 +477,7 @@ mtype {space}"MTYPE:"{space} IStringStream nFlagsStream(YYText()); - nFlagsForStream = readLabel(nFlagsStream); + readLabel(nFlagsStream); BEGIN(cellStreamTitle); } @@ -510,7 +509,6 @@ mtype {space}"MTYPE:"{space} // reset current group ID and a number of flags curGroupID = 0; - nFlagsForStream = 0; } @@ -522,7 +520,6 @@ mtype {space}"MTYPE:"{space} // reset current group ID and a number of flags curGroupID = 0; - nFlagsForStream = 0; BEGIN(INITIAL); } diff --git a/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H b/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H index 585282235a..1505b74e45 100644 --- a/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H +++ b/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H @@ -426,7 +426,7 @@ if (pFaces[WEDGE].size() && pFaces[WEDGE][0].size()) for ( ; - iterf != pFaces[WEDGE][0].end(), iterb != pFaces[WEDGE][1].end(); + iterf != pFaces[WEDGE][0].end() && iterb != pFaces[WEDGE][1].end(); ++iterf, ++iterb ) { @@ -585,4 +585,3 @@ Info << "Writing cell zoning info to file: " << czPath << endl; OFstream cz(czPath); cz << cellZoning << endl; - diff --git a/applications/utilities/miscellaneous/patchSummary/patchSummaryTemplates.C b/applications/utilities/miscellaneous/patchSummary/patchSummaryTemplates.C index 4f130eedf1..c0cc32b25c 100644 --- a/applications/utilities/miscellaneous/patchSummary/patchSummaryTemplates.C +++ b/applications/utilities/miscellaneous/patchSummary/patchSummaryTemplates.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -37,8 +37,6 @@ void Foam::addToFieldList const typename GeoField::Mesh& mesh ) { - typedef GeoField fieldType; - if (obj.headerClassName() == GeoField::typeName) { fieldList.set diff --git a/src/ODE/ODESolvers/Euler/Euler.H b/src/ODE/ODESolvers/Euler/Euler.H index 3cefc425be..fecfc57fa0 100644 --- a/src/ODE/ODESolvers/Euler/Euler.H +++ b/src/ODE/ODESolvers/Euler/Euler.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -81,6 +81,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/EulerSI/EulerSI.H b/src/ODE/ODESolvers/EulerSI/EulerSI.H index 656e3df0a4..a6703cc20c 100644 --- a/src/ODE/ODESolvers/EulerSI/EulerSI.H +++ b/src/ODE/ODESolvers/EulerSI/EulerSI.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -88,6 +88,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/RKCK45/RKCK45.H b/src/ODE/ODESolvers/RKCK45/RKCK45.H index 5402c6efbd..c376a5f423 100644 --- a/src/ODE/ODESolvers/RKCK45/RKCK45.H +++ b/src/ODE/ODESolvers/RKCK45/RKCK45.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -104,6 +104,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/RKDP45/RKDP45.H b/src/ODE/ODESolvers/RKDP45/RKDP45.H index e9ac93592a..b3f5c7bca4 100644 --- a/src/ODE/ODESolvers/RKDP45/RKDP45.H +++ b/src/ODE/ODESolvers/RKDP45/RKDP45.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -108,6 +108,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/RKF45/RKF45.H b/src/ODE/ODESolvers/RKF45/RKF45.H index 7567adc959..5198d5553f 100644 --- a/src/ODE/ODESolvers/RKF45/RKF45.H +++ b/src/ODE/ODESolvers/RKF45/RKF45.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -108,6 +108,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/Rosenbrock12/Rosenbrock12.H b/src/ODE/ODESolvers/Rosenbrock12/Rosenbrock12.H index 7635e9a250..b0bf1c79ef 100644 --- a/src/ODE/ODESolvers/Rosenbrock12/Rosenbrock12.H +++ b/src/ODE/ODESolvers/Rosenbrock12/Rosenbrock12.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -98,6 +98,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/Rosenbrock23/Rosenbrock23.H b/src/ODE/ODESolvers/Rosenbrock23/Rosenbrock23.H index ec9fb76504..38541a7c99 100644 --- a/src/ODE/ODESolvers/Rosenbrock23/Rosenbrock23.H +++ b/src/ODE/ODESolvers/Rosenbrock23/Rosenbrock23.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -102,6 +102,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/Rosenbrock34/Rosenbrock34.H b/src/ODE/ODESolvers/Rosenbrock34/Rosenbrock34.H index 17da8dad05..2af18e5d40 100644 --- a/src/ODE/ODESolvers/Rosenbrock34/Rosenbrock34.H +++ b/src/ODE/ODESolvers/Rosenbrock34/Rosenbrock34.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -110,6 +110,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/Trapezoid/Trapezoid.H b/src/ODE/ODESolvers/Trapezoid/Trapezoid.H index c52d80f51d..667b6ee2ad 100644 --- a/src/ODE/ODESolvers/Trapezoid/Trapezoid.H +++ b/src/ODE/ODESolvers/Trapezoid/Trapezoid.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -71,6 +71,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/rodas23/rodas23.H b/src/ODE/ODESolvers/rodas23/rodas23.H index eceb512bbb..75f0262813 100644 --- a/src/ODE/ODESolvers/rodas23/rodas23.H +++ b/src/ODE/ODESolvers/rodas23/rodas23.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -102,6 +102,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/ODE/ODESolvers/rodas34/rodas34.H b/src/ODE/ODESolvers/rodas34/rodas34.H index 68631bb020..35cb468f6a 100644 --- a/src/ODE/ODESolvers/rodas34/rodas34.H +++ b/src/ODE/ODESolvers/rodas34/rodas34.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -103,6 +103,9 @@ public: // Member Functions + //- Inherit solve from ODESolver + using ODESolver::solve; + //- Solve a single step dx and return the error scalar solve ( diff --git a/src/OSspecific/POSIX/signals/sigFpe.H b/src/OSspecific/POSIX/signals/sigFpe.H index 4129749cc7..c9e9b40f9a 100644 --- a/src/OSspecific/POSIX/signals/sigFpe.H +++ b/src/OSspecific/POSIX/signals/sigFpe.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -71,25 +71,21 @@ class sigFpe //- Saved old signal trapping setting static struct sigaction oldAction_; -# ifdef LINUX - + #ifdef LINUX //- Saved old malloc static void *(*oldMallocHook_)(size_t, const void *); //- NaN malloc function. From malloc_hook manpage. static void* nanMallocHook_(size_t size, const void *caller); - -# endif + #endif // Static data members -# ifdef LINUX_GNUC - + #ifdef LINUX_GNUC //- Handler for caught signals static void sigHandler(int); - -# endif + #endif public: @@ -113,7 +109,6 @@ public: //- Helper: fill block of data with NaN static void fillSignallingNan(UList&); - }; diff --git a/src/OpenFOAM/db/IOobject/IOobject.H b/src/OpenFOAM/db/IOobject/IOobject.H index 5052f66310..da8f443447 100644 --- a/src/OpenFOAM/db/IOobject/IOobject.H +++ b/src/OpenFOAM/db/IOobject/IOobject.H @@ -431,9 +431,7 @@ public: }; -#if defined (__GNUC__) template<> -#endif Ostream& operator<<(Ostream& os, const InfoProxy& ip); diff --git a/src/OpenFOAM/db/IOobject/IOobjectIO.C b/src/OpenFOAM/db/IOobject/IOobjectIO.C index 0bd52beb6e..58664653dc 100644 --- a/src/OpenFOAM/db/IOobject/IOobjectIO.C +++ b/src/OpenFOAM/db/IOobject/IOobjectIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -21,11 +21,6 @@ License You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . -Description - Print a summary of the data described by the IOobject (for - use in erroring, etc.) via the global 'Info' error - mechanism. - \*---------------------------------------------------------------------------*/ #include "IOobject.H" @@ -33,9 +28,7 @@ Description // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -#if defined (__GNUC__) template<> -#endif Foam::Ostream& Foam::operator<<(Ostream& os, const InfoProxy& ip) { const IOobject& io = ip.t_; diff --git a/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.C b/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.C index 0a28f44e09..5b8dd83c35 100644 --- a/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.C +++ b/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -227,20 +227,12 @@ Foam::Ostream& Foam::operator<<(Ostream& os, const IOstream::versionNumber& vn) } - -namespace Foam +template<> +Foam::Ostream& Foam::operator<<(Ostream& os, const InfoProxy& ip) { - -# if defined (__GNUC__) - template<> -# endif - Ostream& operator<<(Ostream& os, const InfoProxy& ip) - { - ip.t_.print(os); - return os; - } - -} // end namespace + ip.t_.print(os); + return os; +} // ************************************************************************* // diff --git a/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.H b/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.H index 95d4a5f311..0fe6ede26a 100644 --- a/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.H +++ b/src/OpenFOAM/db/IOstreams/IOstreams/IOstream.H @@ -52,10 +52,6 @@ SourceFiles #include -#if __GNUC__ < 3 -# define ios_base ios -#endif - using std::ios_base; using std::istream; using std::ostream; @@ -543,6 +539,9 @@ public: Ostream& operator<<(Ostream& os, const IOstream::streamFormat& sf); Ostream& operator<<(Ostream& os, const IOstream::versionNumber& vn); +template<> +Ostream& operator<<(Ostream& os, const InfoProxy& ip); + // -------------------------------------------------------------------- // ------ Manipulators (not taking arguments) diff --git a/src/OpenFOAM/db/IOstreams/StringStreams/OStringStream.H b/src/OpenFOAM/db/IOstreams/StringStreams/OStringStream.H index 57a789bbcf..896f3cfc5d 100644 --- a/src/OpenFOAM/db/IOstreams/StringStreams/OStringStream.H +++ b/src/OpenFOAM/db/IOstreams/StringStreams/OStringStream.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -119,11 +119,7 @@ public: //- Rewind the OStringStream void rewind() { - #if __GNUC__ < 4 && __GNUC_MINOR__ < 4 - stdStream().rdbuf()->pubsetbuf(" ", 1); - #else stdStream().rdbuf()->pubseekpos(0); - #endif } diff --git a/src/OpenFOAM/db/IOstreams/token/token.H b/src/OpenFOAM/db/IOstreams/token/token.H index a1523fd3ff..3b5775b955 100644 --- a/src/OpenFOAM/db/IOstreams/token/token.H +++ b/src/OpenFOAM/db/IOstreams/token/token.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -433,9 +433,12 @@ public: Ostream& operator<<(Ostream&, const token::punctuationToken&); ostream& operator<<(ostream&, const token::punctuationToken&); -ostream& operator<<(ostream&, const InfoProxy&); Ostream& operator<<(Ostream&, const token::compound&); +ostream& operator<<(ostream&, const InfoProxy&); + +template<> +Ostream& operator<<(Ostream& os, const InfoProxy& ip); #define defineCompoundTypeName(Type, Name) \ defineTemplateTypeNameAndDebugWithName(token::Compound, #Type, 0); diff --git a/src/OpenFOAM/db/IOstreams/token/tokenIO.C b/src/OpenFOAM/db/IOstreams/token/tokenIO.C index f45386d8a6..7dc65240b8 100644 --- a/src/OpenFOAM/db/IOstreams/token/tokenIO.C +++ b/src/OpenFOAM/db/IOstreams/token/tokenIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -21,9 +21,6 @@ License You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . -Description - Stream operators for token - \*---------------------------------------------------------------------------*/ #include "error.H" @@ -209,14 +206,8 @@ ostream& Foam::operator<<(ostream& os, const InfoProxy& ip) } -// template specialization -namespace Foam -{ - -#if defined (__GNUC__) template<> -#endif -Ostream& operator<<(Ostream& os, const InfoProxy& ip) +Foam::Ostream& Foam::operator<<(Ostream& os, const InfoProxy& ip) { const token& t = ip.t_; @@ -287,8 +278,4 @@ Ostream& operator<<(Ostream& os, const InfoProxy& ip) } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/db/dictionary/dictionaryEntry/dictionaryEntryIO.C b/src/OpenFOAM/db/dictionary/dictionaryEntry/dictionaryEntryIO.C index 0dbc25e36e..677d5beaac 100644 --- a/src/OpenFOAM/db/dictionary/dictionaryEntry/dictionaryEntryIO.C +++ b/src/OpenFOAM/db/dictionary/dictionaryEntry/dictionaryEntryIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -21,9 +21,6 @@ License You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . -Description - DictionaryEntry constructor from Istream and Ostream output operator. - \*---------------------------------------------------------------------------*/ #include "keyType.H" @@ -87,9 +84,7 @@ Foam::Ostream& Foam::operator<<(Ostream& os, const dictionaryEntry& de) } -#if defined (__GNUC__) template<> -#endif Foam::Ostream& Foam::operator<< ( Ostream& os, diff --git a/src/OpenFOAM/db/dictionary/primitiveEntry/primitiveEntry.H b/src/OpenFOAM/db/dictionary/primitiveEntry/primitiveEntry.H index aa2c2ed36a..2930e5f121 100644 --- a/src/OpenFOAM/db/dictionary/primitiveEntry/primitiveEntry.H +++ b/src/OpenFOAM/db/dictionary/primitiveEntry/primitiveEntry.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -127,6 +127,9 @@ public: // Member functions + //- Inherit read from ITstream + using ITstream::read; + //- Return the dictionary name const fileName& name() const { @@ -163,7 +166,7 @@ public: dictionary& dict(); //- Read tokens from the given stream - bool read(const dictionary&, Istream&); + virtual bool read(const dictionary&, Istream&); //- Write void write(Ostream&) const; diff --git a/src/OpenFOAM/db/functionObjects/IOOutputFilter/IOOutputFilter.H b/src/OpenFOAM/db/functionObjects/IOOutputFilter/IOOutputFilter.H index ab8872798a..f466832690 100644 --- a/src/OpenFOAM/db/functionObjects/IOOutputFilter/IOOutputFilter.H +++ b/src/OpenFOAM/db/functionObjects/IOOutputFilter/IOOutputFilter.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -119,9 +119,15 @@ public: return IOdictionary::name(); } + //- Inherit read from OutputFilter + using OutputFilter::read; + //- Read output filter properties virtual bool read(); + //- Inherit write from regIOobject + using regIOobject::write; + //- Sample and write virtual void write(); diff --git a/src/OpenFOAM/matrices/LduMatrix/LduMatrix/LduInterfaceField/LduInterfaceField.H b/src/OpenFOAM/matrices/LduMatrix/LduMatrix/LduInterfaceField/LduInterfaceField.H index 3d497e93fa..aa21af6b43 100644 --- a/src/OpenFOAM/matrices/LduMatrix/LduMatrix/LduInterfaceField/LduInterfaceField.H +++ b/src/OpenFOAM/matrices/LduMatrix/LduMatrix/LduInterfaceField/LduInterfaceField.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -90,6 +90,9 @@ public: // Coupled interface functionality + //- Inherit initInterfaceMatrixUpdate from lduInterfaceField + using lduInterfaceField::initInterfaceMatrixUpdate; + //- Initialise neighbour matrix update virtual void initInterfaceMatrixUpdate ( @@ -100,6 +103,9 @@ public: ) const {} + //- Inherit updateInterfaceMatrix from lduInterfaceField + using lduInterfaceField::updateInterfaceMatrix; + //- Update result field based on interface functionality virtual void updateInterfaceMatrix ( diff --git a/src/OpenFOAM/memory/tmp/tmp.H b/src/OpenFOAM/memory/tmp/tmp.H index 845199717f..fd6a0c0335 100644 --- a/src/OpenFOAM/memory/tmp/tmp.H +++ b/src/OpenFOAM/memory/tmp/tmp.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -38,7 +38,7 @@ SourceFiles #include "refCount.H" #include -#if defined(__GNUC__) && !defined(__INTEL_COMPILER) +#ifndef __INTEL_COMPILER # define ConstructFromTmp #endif diff --git a/src/OpenFOAM/meshes/meshShapes/cellModel/cellModel.H b/src/OpenFOAM/meshes/meshShapes/cellModel/cellModel.H index 1a165ce505..b78d05f040 100644 --- a/src/OpenFOAM/meshes/meshShapes/cellModel/cellModel.H +++ b/src/OpenFOAM/meshes/meshShapes/cellModel/cellModel.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -175,6 +175,10 @@ public: }; +template<> +Ostream& operator<<(Ostream& os, const InfoProxy& ip); + + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // } // End namespace Foam diff --git a/src/OpenFOAM/meshes/meshShapes/cellModel/cellModelIO.C b/src/OpenFOAM/meshes/meshShapes/cellModel/cellModelIO.C index f9f7f77b2f..1cd60ab8d2 100644 --- a/src/OpenFOAM/meshes/meshShapes/cellModel/cellModelIO.C +++ b/src/OpenFOAM/meshes/meshShapes/cellModel/cellModelIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -21,10 +21,6 @@ License You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . -Description - Read construct cellPrimitiveModel from Istream. - Write cellPrimitiveModel to Ostream - \*---------------------------------------------------------------------------*/ #include "cellModel.H" @@ -32,12 +28,7 @@ Description // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -namespace Foam -{ - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -cellModel::cellModel(Istream& is) +Foam::cellModel::cellModel(Istream& is) { dictionaryEntry entry(dictionary::null, is); name_ = entry.keyword(); @@ -48,7 +39,7 @@ cellModel::cellModel(Istream& is) } -Ostream& operator<<(Ostream& os, const cellModel& c) +Foam::Ostream& Foam::operator<<(Ostream& os, const cellModel& c) { os << "name" << tab << c.name_ << tab << "index" << tab << c.index_ << tab @@ -60,10 +51,8 @@ Ostream& operator<<(Ostream& os, const cellModel& c) } -#if defined (__GNUC__) template<> -#endif -Ostream& operator<<(Ostream& os, const InfoProxy& ip) +Foam::Ostream& Foam::operator<<(Ostream& os, const InfoProxy& ip) { const cellModel& cm = ip.t_; @@ -78,8 +67,4 @@ Ostream& operator<<(Ostream& os, const InfoProxy& ip) } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/meshes/meshShapes/cellShape/cellShape.H b/src/OpenFOAM/meshes/meshShapes/cellShape/cellShape.H index 49e3a4231d..371d95a063 100644 --- a/src/OpenFOAM/meshes/meshShapes/cellShape/cellShape.H +++ b/src/OpenFOAM/meshes/meshShapes/cellShape/cellShape.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -164,6 +164,10 @@ public: }; +template<> +Ostream& operator<<(Ostream& os, const InfoProxy& ip); + + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // } // End namespace Foam diff --git a/src/OpenFOAM/meshes/meshShapes/cellShape/cellShapeIO.C b/src/OpenFOAM/meshes/meshShapes/cellShape/cellShapeIO.C index eeb054549c..9a2854cdb7 100644 --- a/src/OpenFOAM/meshes/meshShapes/cellShape/cellShapeIO.C +++ b/src/OpenFOAM/meshes/meshShapes/cellShape/cellShapeIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -21,9 +21,6 @@ License You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . -Description - Reads a cellShape - \*---------------------------------------------------------------------------*/ #include "cellShape.H" @@ -32,12 +29,7 @@ Description // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -namespace Foam -{ - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -Istream& operator>>(Istream& is, cellShape& s) +Foam::Istream& Foam::operator>>(Istream& is, cellShape& s) { bool readEndBracket = false; @@ -100,7 +92,7 @@ Istream& operator>>(Istream& is, cellShape& s) } -Ostream& operator<<(Ostream& os, const cellShape & s) +Foam::Ostream& Foam::operator<<(Ostream& os, const cellShape & s) { // Write beginning of record os << token::BEGIN_LIST; @@ -121,10 +113,8 @@ Ostream& operator<<(Ostream& os, const cellShape & s) } -#if defined (__GNUC__) template<> -#endif -Ostream& operator<<(Ostream& os, const InfoProxy& ip) +Foam::Ostream& Foam::operator<<(Ostream& os, const InfoProxy& ip) { const cellShape& cs = ip.t_; @@ -148,8 +138,4 @@ Ostream& operator<<(Ostream& os, const InfoProxy& ip) } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/polyPatch.H b/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/polyPatch.H index 357e81c932..b13faf0968 100644 --- a/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/polyPatch.H +++ b/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/polyPatch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -91,6 +91,9 @@ protected: // Protected Member Functions + //- Inherit movePoints from primitivePatch + using primitivePatch::movePoints; + // The polyPatch geometry initialisation is called by polyBoundaryMesh friend class polyBoundaryMesh; diff --git a/src/OpenFOAM/primitives/functions/DataEntry/Table/Table.H b/src/OpenFOAM/primitives/functions/DataEntry/Table/Table.H index e89234cfa9..950c3790a6 100644 --- a/src/OpenFOAM/primitives/functions/DataEntry/Table/Table.H +++ b/src/OpenFOAM/primitives/functions/DataEntry/Table/Table.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -108,42 +108,23 @@ public: // Manipulation - //- Convert time - virtual void convertTimeBase(const Time& t) - { - TableBase::convertTimeBase(t); - } + //- Inherit convertTimeBase from TableBase + using TableBase::convertTimeBase; // Evaluation - //- Return Table value - virtual Type value(const scalar x) const - { - return TableBase::value(x); - } + //- Inherit value from TableBase + using TableBase::value; - //- Integrate between two (scalar) values - virtual Type integrate(const scalar x1, const scalar x2) const - { - return TableBase::integrate(x1, x2); - } + //- Inherit integrate from TableBase + using TableBase::integrate; - //- Return dimensioned constant value - virtual dimensioned dimValue(const scalar x) const - { - return TableBase::dimValue(x); - } + //- Inherit dimValue from TableBase + using TableBase::dimValue; - //- Integrate between two values and return dimensioned type - virtual dimensioned dimIntegrate - ( - const scalar x1, - const scalar x2 - ) - { - return TableBase::dimIntegrate(x1, x2); - } + //- Inherit dimIntegrate from TableBase + using TableBase::dimIntegrate; // I/O diff --git a/src/OpenFOAM/primitives/functions/DataEntry/TableFile/TableFile.H b/src/OpenFOAM/primitives/functions/DataEntry/TableFile/TableFile.H index 23cb53f4e8..537fa20a70 100644 --- a/src/OpenFOAM/primitives/functions/DataEntry/TableFile/TableFile.H +++ b/src/OpenFOAM/primitives/functions/DataEntry/TableFile/TableFile.H @@ -126,42 +126,23 @@ public: // Manipulation - //- Convert time - virtual void convertTimeBase(const Time& t) - { - TableBase::convertTimeBase(t); - } + //- Inherit convertTimeBase from TableBase + using TableBase::convertTimeBase; // Evaluation - //- Return TableFile value - virtual Type value(const scalar x) const - { - return TableBase::value(x); - } + //- Inherit value from TableBase + using TableBase::value; - //- Integrate between two (scalar) values - virtual Type integrate(const scalar x1, const scalar x2) const - { - return TableBase::integrate(x1, x2); - } + //- Inherit integrate from TableBase + using TableBase::integrate; - //- Return dimensioned constant value - virtual dimensioned dimValue(const scalar x) const - { - return TableBase::dimValue(x); - } + //- Inherit dimValue from TableBase + using TableBase::dimValue; - //- Integrate between two values and return dimensioned type - virtual dimensioned dimIntegrate - ( - const scalar x1, - const scalar x2 - ) - { - return TableBase::dimIntegrate(x1, x2); - } + //- Inherit dimIntegrate from TableBase + using TableBase::dimIntegrate; // I/O diff --git a/src/OpenFOAM/primitives/hashes/SHA1/SHA1.C b/src/OpenFOAM/primitives/hashes/SHA1/SHA1.C index 134e2f3af5..f9caa9b586 100644 --- a/src/OpenFOAM/primitives/hashes/SHA1/SHA1.C +++ b/src/OpenFOAM/primitives/hashes/SHA1/SHA1.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -56,10 +56,10 @@ static const unsigned char fillbuf[64] = { 0x80, 0 /* , 0, 0, ... */ }; inline uint32_t Foam::SHA1::swapBytes(uint32_t n) { -#ifdef __BYTE_ORDER -# if (__BYTE_ORDER == __BIG_ENDIAN) + #ifdef __BYTE_ORDER + # if (__BYTE_ORDER == __BIG_ENDIAN) return n; -# else + # else return ( ((n) << 24) @@ -67,9 +67,9 @@ inline uint32_t Foam::SHA1::swapBytes(uint32_t n) | (((n) >> 8) & 0xff00) | ((n) >> 24) ); -# endif + # endif -#else + #else const short x = 0x0100; @@ -88,12 +88,11 @@ inline uint32_t Foam::SHA1::swapBytes(uint32_t n) | ((n) >> 24) ); } -#endif + #endif } -inline void -Foam::SHA1::set_uint32(unsigned char *cp, uint32_t v) +inline void Foam::SHA1::set_uint32(unsigned char *cp, uint32_t v) { memcpy(cp, &v, sizeof(uint32_t)); } @@ -101,7 +100,6 @@ Foam::SHA1::set_uint32(unsigned char *cp, uint32_t v) // * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * * // - void Foam::SHA1::processBytes(const void *data, size_t len) { // already finalized, thus need to restart from nothing @@ -141,29 +139,12 @@ void Foam::SHA1::processBytes(const void *data, size_t len) } // Process available complete blocks -// if (len >= 64) -// { -//#if !_STRING_ARCH_unaligned -//# define alignof(type) offsetof (struct { char c; type x; }, x) -//# define UNALIGNED_P(p) (((size_t) p) % alignof (uint32_t) != 0) -// if (UNALIGNED_P (data)) -// { -// while (len > 64) - while (len >= 64) - { - processBlock(memcpy(buffer_, data, 64), 64); - data = reinterpret_cast(data) + 64; - len -= 64; - } -// } -// else -//#endif -// { -// processBlock(data, len & ~63); -// data = reinterpret_cast(data) + (len & ~63); -// len &= 63; -// } -// } + while (len >= 64) + { + processBlock(memcpy(buffer_, data, 64), 64); + data = reinterpret_cast(data) + 64; + len -= 64; + } // Move remaining bytes in internal buffer. if (len > 0) @@ -199,8 +180,7 @@ void Foam::SHA1::processBytes(const void *data, size_t len) // Process LEN bytes of BUFFER, it is assumed that LEN % 64 == 0. // Most of this code comes from GnuPG's cipher/sha1.c -void -Foam::SHA1::processBlock(const void *data, size_t len) +void Foam::SHA1::processBlock(const void *data, size_t len) { const uint32_t *words = reinterpret_cast(data); size_t nwords = len / sizeof(uint32_t); @@ -224,19 +204,18 @@ Foam::SHA1::processBlock(const void *data, size_t len) } // rotate left uint32_t by n bits -#define rol_uint32(x, nbits) (((x) << (nbits)) | ((x) >> (32 - (nbits)))) + #define rol_uint32(x, nbits) (((x) << (nbits)) | ((x) >> (32 - (nbits)))) -#define M(I) ( tm = x[I & 0x0F] ^ x[(I-14) & 0x0F] \ + #define M(I) ( tm = x[I & 0x0F] ^ x[(I-14) & 0x0F] \ ^ x[(I-8) & 0x0F] ^ x[(I-3) & 0x0F] \ , (x[I & 0x0F] = rol_uint32(tm, 1)) ) - -#define R(A,B,C,D,E,F,K,M) \ - do \ - { \ - E += rol_uint32(A, 5) + F(B, C, D) + K + M; \ - B = rol_uint32(B, 30); \ - } while (0) + #define R(A,B,C,D,E,F,K,M) \ + do \ + { \ + E += rol_uint32(A, 5) + F(B, C, D) + K + M; \ + B = rol_uint32(B, 30); \ + } while (0) while (words < endp) { @@ -357,19 +336,8 @@ void Foam::SHA1::calcDigest(SHA1Digest& dig) const } -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // - -// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // - - // * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * // - void Foam::SHA1::clear() { hashsumA_ = 0x67452301; @@ -446,18 +414,4 @@ Foam::SHA1Digest Foam::SHA1::digest() const } -// * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * * // - -// void Foam::SHA1::operator=(const SHA1& rhs) -// { -// // Check for assignment to self -// if (this == &rhs) -// { -// FatalErrorIn("Foam::SHA1::operator=(const Foam::SHA1&)") -// << "Attempted assignment to self" -// << abort(FatalError); -// } -// } - - // ************************************************************************* // diff --git a/src/Pstream/mpi/UPstream.C b/src/Pstream/mpi/UPstream.C index 0c78f86514..74edc518b2 100644 --- a/src/Pstream/mpi/UPstream.C +++ b/src/Pstream/mpi/UPstream.C @@ -304,9 +304,9 @@ void Foam::UPstream::allocatePstreamCommunicator if (index == PstreamGlobals::MPIGroups_.size()) { // Extend storage with dummy values - MPI_Group newGroup; + MPI_Group newGroup = MPI_GROUP_NULL; PstreamGlobals::MPIGroups_.append(newGroup); - MPI_Comm newComm; + MPI_Comm newComm = MPI_COMM_NULL; PstreamGlobals::MPICommunicators_.append(newComm); } else if (index > PstreamGlobals::MPIGroups_.size()) diff --git a/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonLowReWallFunction/epsilonLowReWallFunctionFvPatchScalarField.C b/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonLowReWallFunction/epsilonLowReWallFunctionFvPatchScalarField.C index 77e45418a8..87ff8cd800 100644 --- a/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonLowReWallFunction/epsilonLowReWallFunctionFvPatchScalarField.C +++ b/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonLowReWallFunction/epsilonLowReWallFunctionFvPatchScalarField.C @@ -77,8 +77,6 @@ void Foam::epsilonLowReWallFunctionFvPatchScalarField::calculate const scalarField magGradUw(mag(Uw.snGrad())); - typedef DimensionedField FieldType; - const DimensionedField& G = db().lookupObject > ( diff --git a/src/conversion/ensight/file/ensightFile.C b/src/conversion/ensight/file/ensightFile.C index f2b61d4607..09269edd32 100644 --- a/src/conversion/ensight/file/ensightFile.C +++ b/src/conversion/ensight/file/ensightFile.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -143,6 +143,12 @@ Foam::Ostream& Foam::ensightFile::write } +Foam::Ostream& Foam::ensightFile::write(const char* value) +{ + return write(string(value)); +} + + Foam::Ostream& Foam::ensightFile::write(const string& value) { char buf[80]; @@ -270,7 +276,7 @@ Foam::Ostream& Foam::ensightFile::writeKeyword(const string& key) { if (allowUndef_) { - write(key + " undef"); + write(string(key + " undef")); newline(); write(undefValue_); newline(); diff --git a/src/conversion/ensight/file/ensightFile.H b/src/conversion/ensight/file/ensightFile.H index 18c71fa02f..c9ed781575 100644 --- a/src/conversion/ensight/file/ensightFile.H +++ b/src/conversion/ensight/file/ensightFile.H @@ -120,6 +120,9 @@ public: // Output + //- Inherit write from Ostream + using Ostream::write; + //- Binary write virtual Ostream& write(const char* buf, std::streamsize count); @@ -132,6 +135,9 @@ public: //- Write undef value Ostream& writeUndef(); + //- Write C-string as "%80s" or as binary + Ostream& write(const char* value); + //- Write string as "%80s" or as binary Ostream& write(const string& value); diff --git a/src/finiteVolume/cfdTools/general/porosityModel/porosityModel/porosityModel.H b/src/finiteVolume/cfdTools/general/porosityModel/porosityModel/porosityModel.H index a3b4b0f0e0..3a76645d99 100644 --- a/src/finiteVolume/cfdTools/general/porosityModel/porosityModel/porosityModel.H +++ b/src/finiteVolume/cfdTools/general/porosityModel/porosityModel/porosityModel.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2012-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2012-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -261,6 +261,9 @@ public: //- Write virtual bool writeData(Ostream& os) const; + //- Inherit read from regIOobject + using regIOobject::read; + //- Read porosity dictionary virtual bool read(const dictionary& dict); }; diff --git a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C index 8e3dd89075..1d028e8c4d 100644 --- a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C +++ b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C @@ -133,6 +133,12 @@ void Foam::solutionControl::read(const bool absTolOnly) } +void Foam::solutionControl::read() +{ + read(false); +} + + Foam::label Foam::solutionControl::applyToField ( const word& fieldName, diff --git a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H index 9cd6cbbf16..3517f7121f 100644 --- a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H +++ b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H @@ -102,6 +102,9 @@ protected: //- Read controls from fvSolution dictionary virtual void read(const bool absTolOnly); + //- Read controls from fvSolution dictionary + virtual void read(); + //- Return index of field in residualControl_ if present virtual label applyToField ( diff --git a/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H index 5887bbc3fa..edf53bcede 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H +++ b/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -333,6 +333,9 @@ public: // Evaluation functions + //- Inherit updateCoeffs from fixedValueFvPatchScalarField + using fixedValueFvPatchScalarField::updateCoeffs; + //- Update the coefficients associated with the patch field // using the given patch total pressure and velocity fields virtual void updateCoeffs diff --git a/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H index 8d8bc415a8..1e50c82e29 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H +++ b/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -214,6 +214,9 @@ public: // Evaluation functions + //- Inherit updateCoeffs from fixedValueFvPatchScalarField + using fixedValueFvPatchScalarField::updateCoeffs; + //- Update the coefficients associated with the patch field // using the given patch velocity field virtual void updateCoeffs(const vectorField& Up); diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.H b/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.H index 3a460569c6..a2c4f2c0cc 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.H +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -134,7 +134,7 @@ public: //- Reverse map the given fvsPatchField onto this fvsPatchField virtual void rmap ( - const fvPatchField&, + const fvsPatchField&, const labelList& ) {} diff --git a/src/finiteVolume/fvMesh/fvPatches/basic/coupled/coupledFvPatch.H b/src/finiteVolume/fvMesh/fvPatches/basic/coupled/coupledFvPatch.H index 7fc59ffb95..c5ff5b874a 100644 --- a/src/finiteVolume/fvMesh/fvPatches/basic/coupled/coupledFvPatch.H +++ b/src/finiteVolume/fvMesh/fvPatches/basic/coupled/coupledFvPatch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -128,6 +128,9 @@ public: const labelUList& internalData ) const = 0; + //- Inherit initInternalFieldTransfer from lduInterface + using lduInterface::initInternalFieldTransfer; + //- Initialise neighbour field transfer virtual void initInternalFieldTransfer ( diff --git a/src/finiteVolume/fvMesh/fvPatches/constraint/processor/processorFvPatch.H b/src/finiteVolume/fvMesh/fvPatches/constraint/processor/processorFvPatch.H index 5336d9e071..e61d122d11 100644 --- a/src/finiteVolume/fvMesh/fvPatches/constraint/processor/processorFvPatch.H +++ b/src/finiteVolume/fvMesh/fvPatches/constraint/processor/processorFvPatch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -157,6 +157,9 @@ public: const labelUList& internalData ) const; + //- Inherit initInternalFieldTransfer from coupledFvPatch + using coupledFvPatch::initInternalFieldTransfer; + //- Initialise neighbour field transfer virtual void initInternalFieldTransfer ( diff --git a/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledFvPatch.H b/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledFvPatch.H index 9c22929437..3a15e78b44 100644 --- a/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledFvPatch.H +++ b/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledFvPatch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -132,6 +132,9 @@ public: const labelUList& internalData ) const; + //- Inherit initInternalFieldTransfer from lduInterface + using lduInterface::initInternalFieldTransfer; + //- Initialise neighbour field transfer virtual void initInternalFieldTransfer ( diff --git a/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledWallFvPatch.H b/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledWallFvPatch.H index 486c5c693d..6cd9b3ecec 100644 --- a/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledWallFvPatch.H +++ b/src/finiteVolume/fvMesh/fvPatches/derived/regionCoupled/regionCoupledWallFvPatch.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -136,6 +136,9 @@ public: const labelUList& internalData ) const; + //- Inherit initInternalFieldTransfer from lduInterface + using lduInterface::initInternalFieldTransfer; + //- Initialise neighbour field transfer virtual void initInternalFieldTransfer ( diff --git a/src/finiteVolume/interpolation/interpolation/interpolationPointMVC/interpolationPointMVC.H b/src/finiteVolume/interpolation/interpolation/interpolationPointMVC/interpolationPointMVC.H index 7e9c4aa893..134e2ade97 100644 --- a/src/finiteVolume/interpolation/interpolation/interpolationPointMVC/interpolationPointMVC.H +++ b/src/finiteVolume/interpolation/interpolation/interpolationPointMVC/interpolationPointMVC.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -75,6 +75,9 @@ public: // Member Functions + //- Inherit interpolate from interpolation + using interpolation::interpolate; + //- Interpolate field for the given cellPointWeight inline Type interpolate(const pointMVCWeight& cpw) const; diff --git a/src/fvOptions/fvOption/fvIOoptionList.H b/src/fvOptions/fvOption/fvIOoptionList.H index 2723b583bd..135c3367fa 100644 --- a/src/fvOptions/fvOption/fvIOoptionList.H +++ b/src/fvOptions/fvOption/fvIOoptionList.H @@ -77,13 +77,16 @@ public: IOoptionList(const fvMesh& mesh); - //- Destructor - virtual ~IOoptionList() - {} + //- Destructor + virtual ~IOoptionList() + {} // Member Functions + //- Inherit read from optionList + using optionList::read; + //- Read dictionary virtual bool read(); }; diff --git a/src/fvOptions/sources/interRegion/interRegionHeatTransfer/interRegionHeatTransferModel/interRegionHeatTransferModel.H b/src/fvOptions/sources/interRegion/interRegionHeatTransfer/interRegionHeatTransferModel/interRegionHeatTransferModel.H index 9066ce40e1..f24bbad670 100644 --- a/src/fvOptions/sources/interRegion/interRegionHeatTransfer/interRegionHeatTransferModel/interRegionHeatTransferModel.H +++ b/src/fvOptions/sources/interRegion/interRegionHeatTransfer/interRegionHeatTransferModel/interRegionHeatTransferModel.H @@ -90,6 +90,9 @@ protected: //- Set the neighbour interRegionHeatTransferModel void setNbrModel(); + //- Inherit correct from interRegionOption + using interRegionOption::correct; + //- Correct to calculate the inter-region heat transfer coefficient void correct(); diff --git a/src/lagrangian/basic/IOPosition/IOPosition.H b/src/lagrangian/basic/IOPosition/IOPosition.H index e4836f556d..4eff22391f 100644 --- a/src/lagrangian/basic/IOPosition/IOPosition.H +++ b/src/lagrangian/basic/IOPosition/IOPosition.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -66,7 +66,6 @@ public: virtual const word& type() const { return Cloud::typeName; - //cloud_.type(); } @@ -78,6 +77,9 @@ public: // Member functions + //- Inherit readData from regIOobject + using regIOobject::readData; + virtual void readData(CloudType& c, bool checkClass); virtual bool write() const; diff --git a/src/lagrangian/intermediate/submodels/CloudFunctionObjects/CloudFunctionObject/CloudFunctionObject.H b/src/lagrangian/intermediate/submodels/CloudFunctionObjects/CloudFunctionObject/CloudFunctionObject.H index 616e6314be..523f818e06 100644 --- a/src/lagrangian/intermediate/submodels/CloudFunctionObjects/CloudFunctionObject/CloudFunctionObject.H +++ b/src/lagrangian/intermediate/submodels/CloudFunctionObjects/CloudFunctionObject/CloudFunctionObject.H @@ -66,6 +66,9 @@ class CloudFunctionObject // Private Member Functions + //- Inherite write from CloudSubModelBase + using CloudSubModelBase::write; + //- Write post-processing info virtual void write(); diff --git a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchFlowRateInjection/PatchFlowRateInjection.H b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchFlowRateInjection/PatchFlowRateInjection.H index c666a92648..72ea50e261 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchFlowRateInjection/PatchFlowRateInjection.H +++ b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchFlowRateInjection/PatchFlowRateInjection.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -122,6 +122,9 @@ public: // Member Functions + //- Inherit updateMesh from patchInjectionBase + using patchInjectionBase::updateMesh; + //- Set injector locations when mesh is updated virtual void updateMesh(); @@ -140,6 +143,9 @@ public: // Injection geometry + //- Inherit setPositionAndCell from patchInjectionBase + using patchInjectionBase::setPositionAndCell; + //- Set the injection position and owner cell, tetFace and tetPt virtual void setPositionAndCell ( diff --git a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchInjection/PatchInjection.H b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchInjection/PatchInjection.H index 95a6b50b71..c782ad860d 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchInjection/PatchInjection.H +++ b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/PatchInjection/PatchInjection.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -119,6 +119,9 @@ public: // Member Functions + //- Inherit updateMesh from patchInjectionBase + using patchInjectionBase::updateMesh; + //- Set injector locations when mesh is updated virtual void updateMesh(); @@ -134,6 +137,9 @@ public: // Injection geometry + //- Inherit setPositionAndCell from patchInjectionBase + using patchInjectionBase::setPositionAndCell; + //- Set the injection position and owner cell, tetFace and tetPt virtual void setPositionAndCell ( diff --git a/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.C b/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.C index 399730c950..9a3636619d 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.C +++ b/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -82,17 +82,13 @@ void Foam::NoSurfaceFilm::setParcelProperties ( parcelType&, const label -) -{ - // do nothing -} +) const +{} template -void Foam::NoSurfaceFilm::info(Ostream&) const -{ - // do nothing -} +void Foam::NoSurfaceFilm::info(Ostream&) +{} // ************************************************************************* // diff --git a/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.H b/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.H index b67136aa6a..b2fd4e7cd2 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.H +++ b/src/lagrangian/intermediate/submodels/Kinematic/SurfaceFilmModel/NoSurfaceFilm/NoSurfaceFilm.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -108,13 +108,13 @@ public: ( parcelType& p, const label filmCellI - ); + ) const; // I-O //- Write surface film info to stream - virtual void info(Ostream& os) const; + virtual void info(Ostream& os); }; diff --git a/src/meshTools/coordinateSystems/coordinateSystems.C b/src/meshTools/coordinateSystems/coordinateSystems.C index 1739ecd8e2..34d1b83715 100644 --- a/src/meshTools/coordinateSystems/coordinateSystems.C +++ b/src/meshTools/coordinateSystems/coordinateSystems.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -174,14 +174,14 @@ Foam::wordList Foam::coordinateSystems::toc() const } -bool Foam::coordinateSystems::writeData(Ostream& os, bool subDict) const +bool Foam::coordinateSystems::writeData(Ostream& os) const { os << nl << size() << nl << token::BEGIN_LIST; forAll(*this, i) { os << nl; - operator[](i).writeDict(os, subDict); + operator[](i).writeDict(os, true); } os << token::END_LIST << nl; diff --git a/src/meshTools/coordinateSystems/coordinateSystems.H b/src/meshTools/coordinateSystems/coordinateSystems.H index 7ed818c1ab..a27629aa6c 100644 --- a/src/meshTools/coordinateSystems/coordinateSystems.H +++ b/src/meshTools/coordinateSystems/coordinateSystems.H @@ -133,7 +133,7 @@ public: wordList toc() const; //- Write data - bool writeData(Ostream&, bool subDict=true) const; + bool writeData(Ostream&) const; }; diff --git a/src/meshTools/searchableSurface/searchableBox.H b/src/meshTools/searchableSurface/searchableBox.H index d677c1b87d..81e47680df 100644 --- a/src/meshTools/searchableSurface/searchableBox.H +++ b/src/meshTools/searchableSurface/searchableBox.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -71,6 +71,9 @@ private: pointIndexHit& info ) const; + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + //- Returns miss or hit with face (0..5) pointIndexHit findNearest ( diff --git a/src/meshTools/searchableSurface/searchableCylinder.H b/src/meshTools/searchableSurface/searchableCylinder.H index 2ec3c6671e..fe00bc4258 100644 --- a/src/meshTools/searchableSurface/searchableCylinder.H +++ b/src/meshTools/searchableSurface/searchableCylinder.H @@ -78,6 +78,9 @@ private: // Private Member Functions + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + //- Find nearest point on cylinder. pointIndexHit findNearest ( diff --git a/src/meshTools/searchableSurface/searchableDisk.H b/src/meshTools/searchableSurface/searchableDisk.H index 7bebdbf76a..c31ad42c4a 100644 --- a/src/meshTools/searchableSurface/searchableDisk.H +++ b/src/meshTools/searchableSurface/searchableDisk.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2014-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -71,6 +71,9 @@ private: // Private Member Functions + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + //- Find nearest point on disk pointIndexHit findNearest ( diff --git a/src/meshTools/searchableSurface/searchablePlate.H b/src/meshTools/searchableSurface/searchablePlate.H index af2d732ff6..0cbea9e01a 100644 --- a/src/meshTools/searchableSurface/searchablePlate.H +++ b/src/meshTools/searchableSurface/searchablePlate.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -80,6 +80,9 @@ private: //- Calculate normal direction from span static direction calcNormal(const point&); + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + pointIndexHit findNearest ( const point& sample, diff --git a/src/meshTools/searchableSurface/searchableSphere.H b/src/meshTools/searchableSurface/searchableSphere.H index 50900f9361..d30b83e8da 100644 --- a/src/meshTools/searchableSurface/searchableSphere.H +++ b/src/meshTools/searchableSurface/searchableSphere.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -69,6 +69,9 @@ private: // Private Member Functions + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + //- Find nearest point on sphere. pointIndexHit findNearest ( diff --git a/src/meshTools/searchableSurface/searchableSurfaceCollection.H b/src/meshTools/searchableSurface/searchableSurfaceCollection.H index 7d9c663121..b3153b6576 100644 --- a/src/meshTools/searchableSurface/searchableSurfaceCollection.H +++ b/src/meshTools/searchableSurface/searchableSurfaceCollection.H @@ -88,6 +88,9 @@ private: // Private Member Functions + //- Inherit findNearest from searchableSurface + using searchableSurface::findNearest; + //- Find point nearest to sample. Updates minDistSqr. Sets nearestInfo // and surface index void findNearest diff --git a/src/parallel/decompose/decompositionMethods/multiLevelDecomp/multiLevelDecomp.H b/src/parallel/decompose/decompositionMethods/multiLevelDecomp/multiLevelDecomp.H index 795cf2632a..dbdd582295 100644 --- a/src/parallel/decompose/decompositionMethods/multiLevelDecomp/multiLevelDecomp.H +++ b/src/parallel/decompose/decompositionMethods/multiLevelDecomp/multiLevelDecomp.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -111,6 +111,9 @@ public: // proc boundaries) virtual bool parallelAware() const; + //- Inherit decompose from decompositionMethod + using decompositionMethod::decompose; + //- Return for every coordinate the wanted processor number. Use the // mesh connectivity (if needed) virtual labelList decompose diff --git a/src/parallel/decompose/metisDecomp/metisDecomp.H b/src/parallel/decompose/metisDecomp/metisDecomp.H index 9ea73fab9f..5f92816124 100644 --- a/src/parallel/decompose/metisDecomp/metisDecomp.H +++ b/src/parallel/decompose/metisDecomp/metisDecomp.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -89,6 +89,9 @@ public: return false; } + //- Inherit decompose from decompositionMethod + using decompositionMethod::decompose; + //- Return for every coordinate the wanted processor number. Use the // mesh connectivity (if needed) // Weights get normalised so the minimum value is 1 before truncation diff --git a/src/parallel/decompose/ptscotchDecomp/ptscotchDecomp.H b/src/parallel/decompose/ptscotchDecomp/ptscotchDecomp.H index 2ae75b2960..e0ae30e5cc 100644 --- a/src/parallel/decompose/ptscotchDecomp/ptscotchDecomp.H +++ b/src/parallel/decompose/ptscotchDecomp/ptscotchDecomp.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -112,6 +112,9 @@ public: return true; } + //- Inherit decompose from decompositionMethod + using decompositionMethod::decompose; + //- Return for every coordinate the wanted processor number. Use the // mesh connectivity (if needed). See note on weights in scotchDecomp.H virtual labelList decompose diff --git a/src/parallel/decompose/scotchDecomp/scotchDecomp.H b/src/parallel/decompose/scotchDecomp/scotchDecomp.H index 55b3172ce2..714bdb76fc 100644 --- a/src/parallel/decompose/scotchDecomp/scotchDecomp.H +++ b/src/parallel/decompose/scotchDecomp/scotchDecomp.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -105,6 +105,9 @@ public: return true; } + //- Inherit decompose from decompositionMethod + using decompositionMethod::decompose; + //- Return for every coordinate the wanted processor number. Use the // mesh connectivity (if needed) // Weights get normalised with minimum weight and truncated to diff --git a/src/surfMesh/UnsortedMeshedSurface/UnsortedMeshedSurface.H b/src/surfMesh/UnsortedMeshedSurface/UnsortedMeshedSurface.H index 5aba10529a..1a8cc16d2e 100644 --- a/src/surfMesh/UnsortedMeshedSurface/UnsortedMeshedSurface.H +++ b/src/surfMesh/UnsortedMeshedSurface/UnsortedMeshedSurface.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -316,6 +316,9 @@ public: const labelHashSet& include ) const; + //- Inherit reset from MeshedSurface + using MeshedSurface::reset; + //- Transfer components (points, faces, zone ids). virtual void reset ( diff --git a/src/surfMesh/surfaceFormats/obj/OBJstream.H b/src/surfMesh/surfaceFormats/obj/OBJstream.H index 47da27c51b..a2188a9136 100644 --- a/src/surfMesh/surfaceFormats/obj/OBJstream.H +++ b/src/surfMesh/surfaceFormats/obj/OBJstream.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2012-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2012-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -101,6 +101,9 @@ public: // Ostream implementation + //- Inherit write from Ostream + using Ostream::write; + //- Write character virtual Ostream& write(const char); diff --git a/src/thermophysicalModels/basic/heThermo/heThermo.C b/src/thermophysicalModels/basic/heThermo/heThermo.C index 0cc1354ffa..23441a9b79 100644 --- a/src/thermophysicalModels/basic/heThermo/heThermo.C +++ b/src/thermophysicalModels/basic/heThermo/heThermo.C @@ -799,6 +799,60 @@ Foam::heThermo::alphaEff } +template +Foam::scalar +Foam::heThermo::Cp +( + const label speciei, + const scalar p, + const scalar T +) const +{ + notImplemented + ( + "heThermo::" + "Cp(const label speciei, const scalar p, const scalar T)" + ); + return 0; +} + + +template +Foam::scalar +Foam::heThermo::Cv +( + const label speciei, + const scalar p, + const scalar T +) const +{ + notImplemented + ( + "heThermo::" + "Cv(const label speciei, const scalar p, const scalar T)" + ); + return 0; +} + + +template +Foam::scalar +Foam::heThermo::kappa +( + const label speciei, + const scalar p, + const scalar T +) const +{ + notImplemented + ( + "heThermo::" + "kappa(const label speciei, const scalar p, const scalar T)" + ); + return 0; +} + + template bool Foam::heThermo::read() { diff --git a/src/thermophysicalModels/basic/heThermo/heThermo.H b/src/thermophysicalModels/basic/heThermo/heThermo.H index 9858f16a31..5bf3bdc935 100644 --- a/src/thermophysicalModels/basic/heThermo/heThermo.H +++ b/src/thermophysicalModels/basic/heThermo/heThermo.H @@ -292,6 +292,34 @@ public: ) const; + // Dummy per-specie thermo properties to avoid problems + // with virtual function inheritance + + //- Heat capacity at constant pressure [J/(kg K)] + virtual scalar Cp + ( + const label speciei, + const scalar p, + const scalar T + ) const; + + //- Heat capacity at constant volume [J/(kg K)] + virtual scalar Cv + ( + const label speciei, + const scalar p, + const scalar T + ) const; + + //- Thermal conductivity [W/m/K] + virtual scalar kappa + ( + const label speciei, + const scalar p, + const scalar T + ) const; + + //- Read thermophysical properties dictionary virtual bool read(); }; diff --git a/wmake/rules/linux64Clang/c++ b/wmake/rules/linux64Clang/c++ index b4dd352444..300983dc58 100644 --- a/wmake/rules/linux64Clang/c++ +++ b/wmake/rules/linux64Clang/c++ @@ -1,7 +1,6 @@ SUFFIXES += .C -# -Woverloaded-virtual may produce spurious warnings, disable for now -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -Wno-overloaded-virtual -Wno-unused-comparison -Wno-invalid-offsetof -Wno-c++11-extensions +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-c++11-extensions # Suppress CGAL warnings c++CGALWARN = -Wno-sometimes-uninitialized -Wno-mismatched-tags diff --git a/wmake/rules/linux64Gcc/c++ b/wmake/rules/linux64Gcc/c++ index a23dd820ef..4b4f637e25 100644 --- a/wmake/rules/linux64Gcc/c++ +++ b/wmake/rules/linux64Gcc/c++ @@ -1,9 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof # Suppress CGAL warnings -c++CGALWARN = -Wall -Wextra -Wno-unused-parameter -Wno-old-style-cast -Wnon-virtual-dtor +c++CGALWARN = CC = g++ -m64 diff --git a/wmake/rules/linuxARM7Gcc/c++ b/wmake/rules/linuxARM7Gcc/c++ index 408abf7665..67bd5ff30c 100644 --- a/wmake/rules/linuxARM7Gcc/c++ +++ b/wmake/rules/linuxARM7Gcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++ diff --git a/wmake/rules/linuxClang/c++ b/wmake/rules/linuxClang/c++ index ab4226f7a6..c3fe9e6d9c 100644 --- a/wmake/rules/linuxClang/c++ +++ b/wmake/rules/linuxClang/c++ @@ -1,7 +1,6 @@ SUFFIXES += .C -# -Woverloaded-virtual may produce spurious warnings, disable for now -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -Wno-overloaded-virtual -Wno-unused-comparison -Wno-invalid-offsetof -Wno-c++11-extensions +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-c++11-extensions # Suppress CGAL warnings c++CGALWARN = -Wno-sometimes-uninitialized -Wno-mismatched-tags diff --git a/wmake/rules/linuxGcc/c++ b/wmake/rules/linuxGcc/c++ index b00d78f984..2ebcd45d5a 100644 --- a/wmake/rules/linuxGcc/c++ +++ b/wmake/rules/linuxGcc/c++ @@ -1,9 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof # Suppress CGAL warnings -c++CGALWARN = -Wall -Wextra -Wno-unused-parameter -Wno-old-style-cast -Wnon-virtual-dtor +c++CGALWARN = CC = g++ -m32 diff --git a/wmake/rules/linuxIA64Gcc/c++ b/wmake/rules/linuxIA64Gcc/c++ index 1d60843b70..df6b4d8d17 100644 --- a/wmake/rules/linuxIA64Gcc/c++ +++ b/wmake/rules/linuxIA64Gcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++ diff --git a/wmake/rules/linuxPPC64Gcc/c++ b/wmake/rules/linuxPPC64Gcc/c++ index 809364deb7..3dadf71c0b 100644 --- a/wmake/rules/linuxPPC64Gcc/c++ +++ b/wmake/rules/linuxPPC64Gcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++ -m64 -mcpu=power5+ diff --git a/wmake/rules/linuxPPC64leGcc/c++ b/wmake/rules/linuxPPC64leGcc/c++ index 65a63430c3..2e9ad46fe9 100644 --- a/wmake/rules/linuxPPC64leGcc/c++ +++ b/wmake/rules/linuxPPC64leGcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++ -m64 -mcpu=power8 diff --git a/wmake/rules/solaris64Gcc/c++ b/wmake/rules/solaris64Gcc/c++ index 33cdad290d..c156dd9e87 100644 --- a/wmake/rules/solaris64Gcc/c++ +++ b/wmake/rules/solaris64Gcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++ -m64 diff --git a/wmake/rules/solarisGcc/c++ b/wmake/rules/solarisGcc/c++ index 4cb29df20f..df6b4d8d17 100644 --- a/wmake/rules/solarisGcc/c++ +++ b/wmake/rules/solarisGcc/c++ @@ -1,6 +1,9 @@ SUFFIXES += .C -c++WARN = -Wall -Wextra -Wno-unused-parameter -Wno-invalid-offsetof +c++WARN = -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof + +# Suppress CGAL warnings +c++CGALWARN = CC = g++