diff --git a/opm/core/grid/GridHelpers.hpp b/opm/core/grid/GridHelpers.hpp index cb78562f..9ecb7727 100644 --- a/opm/core/grid/GridHelpers.hpp +++ b/opm/core/grid/GridHelpers.hpp @@ -190,10 +190,6 @@ const double* beginCellVolumes(const UnstructuredGrid& grid); /// \brief Get an iterator over the cell volumes of a grid positioned after the last cell. const double* endCellVolumes(const UnstructuredGrid& grid); -/// \brief Get the cell centroid of a face. -/// \param grid The grid whose cell centroid we query. -/// \param face_index The index of the corresponding face. -const double* faceCentroid(const UnstructuredGrid& grid, int face_index); /// \brief Traits of the face centroids of a grid. @@ -220,7 +216,6 @@ beginFaceCentroids(const UnstructuredGrid& grid); /// \brief Get a coordinate of a specific face centroid. /// \param grid The grid. /// \param face_index The index of the specific face. -/// \param coordinate The coordinate index. FaceCentroidTraits::ValueType faceCentroid(const UnstructuredGrid& grid, int face_index); diff --git a/opm/core/linalg/LinearSolverIstl.cpp b/opm/core/linalg/LinearSolverIstl.cpp index 26a7102e..fa63e2fd 100644 --- a/opm/core/linalg/LinearSolverIstl.cpp +++ b/opm/core/linalg/LinearSolverIstl.cpp @@ -466,8 +466,8 @@ namespace Opm double linsolver_prolongate_factor) { // Solve with AMG solver. - typedef Dune::MatrixAdapter Operator; - Operator sOpA(opA.getmat()); + typedef Dune::MatrixAdapter AMGOperator; + AMGOperator sOpA(opA.getmat()); #if FIRST_DIAGONAL typedef Dune::Amg::FirstDiagonal CouplingMetric; @@ -482,7 +482,7 @@ namespace Opm #endif typedef Dune::Amg::CoarsenCriterion Criterion; - typedef Dune::Amg::FastAMG Precond; + typedef Dune::Amg::FastAMG Precond; // Construct preconditioner. Criterion criterion; diff --git a/opm/core/utility/Units.hpp b/opm/core/utility/Units.hpp index 75bee386..55432717 100644 --- a/opm/core/utility/Units.hpp +++ b/opm/core/utility/Units.hpp @@ -35,6 +35,8 @@ #ifndef OPM_UNITS_HEADER #define OPM_UNITS_HEADER + + /** * \file * Constants and routines to assist in handling units of measurement. These are @@ -216,6 +218,16 @@ namespace Opm return q / unit; } } // namespace convert + + +#ifndef HAS_ATTRIBUTE_UNUSED + namespace detail { + // Some units are sometimes unused, and generate a (potentially) large number of warnings + // Adding them here silences these warnings, and should have no side-effects + double __attribute__((unused)) unused_units = stb + liter + barsa + psia + darcy; + } // namespace detail +#endif + } // namespace unit } // namespace Opm #endif // OPM_UNITS_HEADER