mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
fix the dune 2.4 deprecation warnings
mainly this boils down to mapper.map(e) -> mapper.index(e)
This commit is contained in:
@@ -125,10 +125,9 @@ public:
|
||||
Dune::FieldVector<int, dim> cellRes;
|
||||
#endif
|
||||
|
||||
Dune::FieldVector<Scalar, dim> upperRight;
|
||||
Dune::FieldVector<Scalar, dim> lowerLeft;
|
||||
typedef double GridScalar;
|
||||
Dune::FieldVector<GridScalar, dim> upperRight;
|
||||
|
||||
lowerLeft[1] = 0.0;
|
||||
upperRight[0] = EWOMS_GET_PARAM(TypeTag, Scalar, DomainSizeX);
|
||||
upperRight[1] = EWOMS_GET_PARAM(TypeTag, Scalar, DomainSizeY);
|
||||
|
||||
@@ -140,13 +139,17 @@ public:
|
||||
}
|
||||
|
||||
unsigned numRefinements = EWOMS_GET_PARAM(TypeTag, unsigned, GridGlobalRefinements);
|
||||
#if DUNE_VERSION_NEWER(DUNE_COMMON, 2, 4)
|
||||
gridPtr_.reset(new Dune::YaspGrid<dim>(upperRight, cellRes));
|
||||
#else
|
||||
gridPtr_.reset(new Dune::YaspGrid<dim>(
|
||||
#ifdef HAVE_MPI
|
||||
/*mpiCommunicator=*/Dune::MPIHelper::getCommunicator(),
|
||||
/*mpiCommunicator=*/Dune::MPIHelper::getCommunicator(),
|
||||
#endif
|
||||
/*upperRightCorner=*/upperRight,
|
||||
/*numCells=*/cellRes, isPeriodic,
|
||||
/*overlap=*/1));
|
||||
#endif
|
||||
/*upperRightCorner=*/upperRight,
|
||||
/*numCells=*/cellRes, isPeriodic,
|
||||
/*overlap=*/1));
|
||||
gridPtr_->globalRefine(numRefinements);
|
||||
|
||||
this->finalizeInit_();
|
||||
|
||||
@@ -281,6 +281,9 @@ void testQuadrature()
|
||||
|
||||
typedef Dune::YaspGrid<dim> Grid;
|
||||
typedef Grid::LeafGridView GridView;
|
||||
#if DUNE_VERSION_NEWER(DUNE_COMMON, 2, 4)
|
||||
Grid grid(upperRight, cellRes);
|
||||
#else
|
||||
Grid grid(
|
||||
#ifdef HAVE_MPI
|
||||
Dune::MPIHelper::getCommunicator(),
|
||||
@@ -288,6 +291,7 @@ void testQuadrature()
|
||||
upperRight, // upper right
|
||||
cellRes, // number of cells
|
||||
isPeriodic, 0); // overlap
|
||||
#endif
|
||||
|
||||
// compute approximate integral
|
||||
#if DUNE_VERSION_NEWER(DUNE_COMMON, 2, 3)
|
||||
|
||||
Reference in New Issue
Block a user