[cleanup] Removes unnecessary if clauses for unsupported DUNE versions.

We are targetting DUNE 2.4.* and 2.5.* currently. Therefore this commit removes
the if checks for lower versions to cleanup the code.
This commit is contained in:
Markus Blatt
2017-10-11 15:53:45 +02:00
parent 0264a1f609
commit 6a5dc78249
6 changed files with 5 additions and 36 deletions

View File

@@ -33,14 +33,7 @@
#include <dune/common/fmatrix.hh>
#include <dune/common/version.hh>
#if DUNE_VERSION_NEWER(DUNE_ISTL,2,4)
#include <dune/istl/bcrsmatrix.hh>
#else
// Include matrix header with hackery to make it possible to inherit.
#define private protected
#include <dune/istl/bcrsmatrix.hh>
#undef private
#endif
#include <opm/common/utility/platform_dependent/reenable_warnings.h>
@@ -90,15 +83,13 @@ namespace Opm
nnz = ia[rows];
#if DUNE_VERSION_NEWER(DUNE_ISTL, 2, 3)
#if DUNE_VERSION_NEWER(DUNE_ISTL, 2, 5)
#if DUNE_VERSION_NEWER(DUNE_ISTL, 2, 5)
this->allocationSize_ = nnz;
#else
#else
this->allocationSize = nnz;
#endif
#endif
this->avg = 0;
this->overflowsize = -1.0;
#endif
// make sure to use the allocators of this matrix
// because the same allocators are used to deallocate the data