From f8c8ae820950ecbc0598fe130c9fe989b3e45b55 Mon Sep 17 00:00:00 2001
From: Elias Pipping <elias.pipping@fu-berlin.de>
Date: Mon, 25 Mar 2013 22:49:02 +0100
Subject: [PATCH] Constness

---
 src/vtk.cc      |  8 ++++----
 src/vtk.hh      |  8 ++++----
 src/vtk_tmpl.cc | 11 +++++++----
 3 files changed, 15 insertions(+), 12 deletions(-)

diff --git a/src/vtk.cc b/src/vtk.cc
index 00c4a2fd..b92b0616 100644
--- a/src/vtk.cc
+++ b/src/vtk.cc
@@ -6,10 +6,10 @@
 
 template <class VertexBasis, class CellBasis, class VectorType,
           class SingletonVectorType, class GridView>
-void writeVtk(VertexBasis vertexBasis, VectorType displacement,
-              SingletonVectorType state, CellBasis cellBasis,
-              SingletonVectorType stress, GridView gridView,
-              std::string filename) {
+void writeVtk(VertexBasis const &vertexBasis, VectorType const &displacement,
+              SingletonVectorType const &state, CellBasis const &cellBasis,
+              SingletonVectorType const &stress, GridView const &gridView,
+              std::string const &filename) {
   Dune::VTKWriter<GridView> writer(gridView);
 
   auto const displacement_ptr =
diff --git a/src/vtk.hh b/src/vtk.hh
index e0d1de16..9986fe90 100644
--- a/src/vtk.hh
+++ b/src/vtk.hh
@@ -8,9 +8,9 @@
 
 template <class VertexBasis, class CellBasis, class VectorType,
           class SingletonVectorType, class GridView>
-void writeVtk(VertexBasis vertexBasis, VectorType displacement,
-              SingletonVectorType state, CellBasis cellBasis,
-              SingletonVectorType stress, GridView gridView,
-              std::string filename);
+void writeVtk(VertexBasis const &vertexBasis, VectorType const &displacement,
+              SingletonVectorType const &state, CellBasis const &cellBasis,
+              SingletonVectorType const &stress, GridView const &gridView,
+              std::string const &filename);
 
 #endif
diff --git a/src/vtk_tmpl.cc b/src/vtk_tmpl.cc
index 23785948..eac4a0cc 100644
--- a/src/vtk_tmpl.cc
+++ b/src/vtk_tmpl.cc
@@ -22,7 +22,10 @@ typedef P1NodalBasis<GridView, double> P1Basis;
 typedef P0Basis<GridView, double> MyP0Basis;
 
 template void writeVtk<P1Basis, MyP0Basis, VectorType, SingletonVectorType,
-                       GridView>(P1Basis vertexBasis, VectorType displacement,
-                                 SingletonVectorType state, MyP0Basis cellBasis,
-                                 SingletonVectorType stress, GridView gridView,
-                                 std::string filename);
+                       GridView>(P1Basis const &vertexBasis,
+                                 VectorType const &displacement,
+                                 SingletonVectorType const &state,
+                                 MyP0Basis const &cellBasis,
+                                 SingletonVectorType const &stress,
+                                 GridView const &gridView,
+                                 std::string const &filename);
-- 
GitLab