mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
fix some masochistic compiler warnings for the GCC 9 pre-release
the flags which I used are ``` -pedantic \ -Wall \ -Wextra \ -Wformat-nonliteral \ -Wcast-align -Wpointer-arith \ -Wmissing-declarations \ -Wcast-qual \ -Wshadow -Wwrite-strings \ -Wchar-subscripts \ -Wredundant-decls \ -fstrict-overflow \ -O3 \ -march=native \ -DNDEBUG=1 ``` note that some heavy filtering is not the worst idea because DUNE is far from not emiting any warnings with these flags. Also, there were some pesky warnings in test_ecl_output which I don't know how to fix: ``` tests/test_ecl_output.cc:218:73: warning: missing initializer for member ‘Opm::data::Connection::effective_Kh’ [-Wmissing-field-initializers] ```
This commit is contained in:
parent
5d581bab7e
commit
18e64d0e7e
@ -86,10 +86,10 @@ public:
|
|||||||
* \brief Add the water which enters or leaves the reservoir due to aquifiers.
|
* \brief Add the water which enters or leaves the reservoir due to aquifiers.
|
||||||
*/
|
*/
|
||||||
template <class Context>
|
template <class Context>
|
||||||
void addToSource(RateVector& rate,
|
void addToSource(RateVector& rate OPM_UNUSED,
|
||||||
const Context& context,
|
const Context& context OPM_UNUSED,
|
||||||
unsigned spaceIdx,
|
unsigned spaceIdx OPM_UNUSED,
|
||||||
unsigned timeIdx) const
|
unsigned timeIdx OPM_UNUSED) const
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@ -122,7 +122,7 @@ public:
|
|||||||
* format.
|
* format.
|
||||||
*/
|
*/
|
||||||
template <class Restarter>
|
template <class Restarter>
|
||||||
void serialize(Restarter& res)
|
void serialize(Restarter& res OPM_UNUSED)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@ -130,7 +130,7 @@ public:
|
|||||||
* format.
|
* format.
|
||||||
*/
|
*/
|
||||||
template <class Restarter>
|
template <class Restarter>
|
||||||
void deserialize(Restarter& res)
|
void deserialize(Restarter& res OPM_UNUSED)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@ -107,7 +107,6 @@ public:
|
|||||||
|
|
||||||
unsigned numElems = vanguard.grid().size(0);
|
unsigned numElems = vanguard.grid().size(0);
|
||||||
unsigned numCartesianElems = vanguard.cartesianSize();
|
unsigned numCartesianElems = vanguard.cartesianSize();
|
||||||
typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem;
|
|
||||||
|
|
||||||
EQUIL::DeckDependent::InitialStateComputer<TypeTag> initialState(materialLawManager,
|
EQUIL::DeckDependent::InitialStateComputer<TypeTag> initialState(materialLawManager,
|
||||||
eclState,
|
eclState,
|
||||||
|
@ -101,7 +101,7 @@ public:
|
|||||||
*
|
*
|
||||||
* I.e., well positions, names etc...
|
* I.e., well positions, names etc...
|
||||||
*/
|
*/
|
||||||
void init(const Opm::EclipseState& eclState,
|
void init(const Opm::EclipseState& eclState OPM_UNUSED,
|
||||||
const Opm::Schedule& deckSchedule)
|
const Opm::Schedule& deckSchedule)
|
||||||
{
|
{
|
||||||
// create the wells which intersect with the current process' grid
|
// create the wells which intersect with the current process' grid
|
||||||
@ -609,7 +609,7 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool wellTopologyChanged_(const Opm::EclipseState& eclState,
|
bool wellTopologyChanged_(const Opm::EclipseState& eclState OPM_UNUSED,
|
||||||
const Opm::Schedule& schedule,
|
const Opm::Schedule& schedule,
|
||||||
unsigned reportStepIdx) const
|
unsigned reportStepIdx) const
|
||||||
{
|
{
|
||||||
|
@ -384,7 +384,6 @@ private:
|
|||||||
}
|
}
|
||||||
|
|
||||||
const auto& globalGridView = globalGrid_.leafGridView();
|
const auto& globalGridView = globalGrid_.leafGridView();
|
||||||
typedef typename Grid::LeafGridView GridView;
|
|
||||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GridView> ElementMapper;
|
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GridView> ElementMapper;
|
||||||
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
||||||
@ -450,7 +449,6 @@ private:
|
|||||||
int ny = eclState().getInputGrid().getNY();
|
int ny = eclState().getInputGrid().getNY();
|
||||||
|
|
||||||
const auto& globalGridView = globalGrid_.leafGridView();
|
const auto& globalGridView = globalGrid_.leafGridView();
|
||||||
typedef typename Grid::LeafGridView GridView;
|
|
||||||
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
#if DUNE_VERSION_NEWER(DUNE_GRID, 2,6)
|
||||||
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GridView> ElementMapper;
|
typedef Dune::MultipleCodimMultipleGeomTypeMapper<GridView> ElementMapper;
|
||||||
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
ElementMapper globalElemMapper(globalGridView, Dune::mcmgElementLayout());
|
||||||
|
@ -713,9 +713,9 @@ phaseSaturations(const Grid& grid,
|
|||||||
/*storeSaturation=*/true,
|
/*storeSaturation=*/true,
|
||||||
/*storeDensity=*/false,
|
/*storeDensity=*/false,
|
||||||
/*storeViscosity=*/false,
|
/*storeViscosity=*/false,
|
||||||
/*storeEnthalpy=*/false> SatOnlyFluidState;
|
/*storeEnthalpy=*/false> MySatOnlyFluidState;
|
||||||
|
|
||||||
SatOnlyFluidState fluidState;
|
MySatOnlyFluidState fluidState;
|
||||||
typedef typename MaterialLawManager::MaterialLaw MaterialLaw;
|
typedef typename MaterialLawManager::MaterialLaw MaterialLaw;
|
||||||
|
|
||||||
const bool water = FluidSystem::phaseIsActive(FluidSystem::waterPhaseIdx);
|
const bool water = FluidSystem::phaseIsActive(FluidSystem::waterPhaseIdx);
|
||||||
@ -1129,7 +1129,7 @@ private:
|
|||||||
}
|
}
|
||||||
|
|
||||||
template <class RMap, class MaterialLawManager>
|
template <class RMap, class MaterialLawManager>
|
||||||
void calcPressSatRsRv(const Opm::EclipseState& eclState,
|
void calcPressSatRsRv(const Opm::EclipseState& eclState OPM_UNUSED,
|
||||||
const RMap& reg,
|
const RMap& reg,
|
||||||
const std::vector< Opm::EquilRecord >& rec,
|
const std::vector< Opm::EquilRecord >& rec,
|
||||||
MaterialLawManager& materialLawManager,
|
MaterialLawManager& materialLawManager,
|
||||||
|
Loading…
Reference in New Issue
Block a user