diff --git a/opm/grid/cpgrid/Entity.hpp b/opm/grid/cpgrid/Entity.hpp index dbc1735aa..f64f7723a 100644 --- a/opm/grid/cpgrid/Entity.hpp +++ b/opm/grid/cpgrid/Entity.hpp @@ -149,7 +149,7 @@ namespace Dune } /// Returns the geometry of the entity (does not depend on its orientation). - const Geometry& geometry() const; + Geometry geometry() const; /// We do not support refinement, so level() is always 0. int level() const @@ -431,7 +431,7 @@ unsigned int Entity::subEntities ( const unsigned int cc ) const } template -const typename Entity::Geometry& Entity::geometry() const +typename Entity::Geometry Entity::geometry() const { return pgrid_->geomVector()[*this]; }