From 1393af2e141014269874122dc8fe071a2bd4ef5c Mon Sep 17 00:00:00 2001
From: Timo Koch <timo.koch@iws.uni-stuttgart.de>
Date: Wed, 3 Jan 2018 16:02:56 +0100
Subject: [PATCH] [io] Avoid deprecation warning for geometry type

---
 dumux/io/cakegridcreator.hh | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/dumux/io/cakegridcreator.hh b/dumux/io/cakegridcreator.hh
index c2bc79619c..89aebc5bc5 100644
--- a/dumux/io/cakegridcreator.hh
+++ b/dumux/io/cakegridcreator.hh
@@ -30,6 +30,7 @@
 #include <cmath>
 #include <algorithm>
 
+#include <dune/common/version.hh>
 #include <dune/common/dynvector.hh>
 #include <dune/grid/common/gridfactory.hh>
 #include <dumux/common/properties.hh>
@@ -274,8 +275,11 @@ public:
         std::vector<Scalar> dA = polarCoordinates[1];
 
         GridFactory gridFactory;
+#if DUNE_VERSION_NEWER(DUNE_COMMON,2,6)
+        constexpr auto type = Dune::GeometryTypes::cube(dim);
+#else
         Dune::GeometryType type; type.makeCube(dim);
-
+#endif
         // create nodes
         if (dim == 3)
         {
-- 
GitLab