From 4203f88589b78cbcec4b6fb2e598e762c9fe39a4 Mon Sep 17 00:00:00 2001 From: Timo Heister Date: Sun, 22 Jan 2017 20:38:35 -0500 Subject: [PATCH] Fix constness of argument in FE::interpolate() Reported by MSVC. --- include/deal.II/fe/fe_abf.h | 4 ++-- include/deal.II/fe/fe_bdm.h | 4 ++-- include/deal.II/fe/fe_dg_vector.h | 4 ++-- include/deal.II/fe/fe_dg_vector.templates.h | 2 +- include/deal.II/fe/fe_nedelec.h | 2 +- include/deal.II/fe/fe_q_bubbles.h | 2 +- include/deal.II/fe/fe_q_dg0.h | 2 +- include/deal.II/fe/fe_q_hierarchical.h | 2 +- include/deal.II/fe/fe_rannacher_turek.h | 2 +- include/deal.II/fe/fe_raviart_thomas.h | 6 +++--- source/fe/fe_abf.cc | 2 +- source/fe/fe_nedelec.cc | 2 +- source/fe/fe_q_bubbles.cc | 2 +- source/fe/fe_q_dg0.cc | 2 +- source/fe/fe_rannacher_turek.cc | 2 +- source/fe/fe_raviart_thomas.cc | 2 +- source/fe/fe_raviart_thomas_nodal.cc | 2 +- 17 files changed, 22 insertions(+), 22 deletions(-) diff --git a/include/deal.II/fe/fe_abf.h b/include/deal.II/fe/fe_abf.h index 0202f6767d..c05cedd3fe 100644 --- a/include/deal.II/fe/fe_abf.h +++ b/include/deal.II/fe/fe_abf.h @@ -124,10 +124,10 @@ public: const unsigned int face_index) const; virtual void interpolate(std::vector &local_dofs, - const std::vector &values) const; + const std::vector &values) const; virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/include/deal.II/fe/fe_bdm.h b/include/deal.II/fe/fe_bdm.h index c49e225dc1..b82b1a2cc4 100644 --- a/include/deal.II/fe/fe_bdm.h +++ b/include/deal.II/fe/fe_bdm.h @@ -73,10 +73,10 @@ public: virtual FiniteElement *clone () const; virtual void interpolate(std::vector &local_dofs, - const std::vector &values) const; + const std::vector &values) const; virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/include/deal.II/fe/fe_dg_vector.h b/include/deal.II/fe/fe_dg_vector.h index c08df9df40..162c87d2d9 100644 --- a/include/deal.II/fe/fe_dg_vector.h +++ b/include/deal.II/fe/fe_dg_vector.h @@ -81,10 +81,10 @@ public: const unsigned int face_index) const; virtual void interpolate(std::vector &local_dofs, - const std::vector &values) const; + const std::vector &values) const; virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/include/deal.II/fe/fe_dg_vector.templates.h b/include/deal.II/fe/fe_dg_vector.templates.h index 63052b2593..96a69334e6 100644 --- a/include/deal.II/fe/fe_dg_vector.templates.h +++ b/include/deal.II/fe/fe_dg_vector.templates.h @@ -105,7 +105,7 @@ void FE_DGVector::interpolate (std::vector & /*local_dofs*/, const std::vector > & /*values*/, - unsigned int /*offset*/) const + const unsigned int /*offset*/) const { Assert(false, ExcNotImplemented()); } diff --git a/include/deal.II/fe/fe_nedelec.h b/include/deal.II/fe/fe_nedelec.h index 6e085d44ab..76ca5beecd 100644 --- a/include/deal.II/fe/fe_nedelec.h +++ b/include/deal.II/fe/fe_nedelec.h @@ -260,7 +260,7 @@ public: virtual void interpolate (std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate (std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/include/deal.II/fe/fe_q_bubbles.h b/include/deal.II/fe/fe_q_bubbles.h index f6261669af..38a5126073 100644 --- a/include/deal.II/fe/fe_q_bubbles.h +++ b/include/deal.II/fe/fe_q_bubbles.h @@ -123,7 +123,7 @@ public: */ virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; /** * Interpolate a set of vector values, computed in the generalized support diff --git a/include/deal.II/fe/fe_q_dg0.h b/include/deal.II/fe/fe_q_dg0.h index 28c24b6347..bc98739be5 100644 --- a/include/deal.II/fe/fe_q_dg0.h +++ b/include/deal.II/fe/fe_q_dg0.h @@ -276,7 +276,7 @@ public: */ virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; /** * Interpolate a set of vector values, computed in the generalized support diff --git a/include/deal.II/fe/fe_q_hierarchical.h b/include/deal.II/fe/fe_q_hierarchical.h index 682f1a75ef..0beb22d7c6 100644 --- a/include/deal.II/fe/fe_q_hierarchical.h +++ b/include/deal.II/fe/fe_q_hierarchical.h @@ -701,7 +701,7 @@ public: void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; /** * This function is not implemented and throws an exception if called. diff --git a/include/deal.II/fe/fe_rannacher_turek.h b/include/deal.II/fe/fe_rannacher_turek.h index 27c6370c25..28dff634fa 100644 --- a/include/deal.II/fe/fe_rannacher_turek.h +++ b/include/deal.II/fe/fe_rannacher_turek.h @@ -73,7 +73,7 @@ public: virtual void interpolate( std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/include/deal.II/fe/fe_raviart_thomas.h b/include/deal.II/fe/fe_raviart_thomas.h index 4fd67eaccf..c49d7ddf6e 100644 --- a/include/deal.II/fe/fe_raviart_thomas.h +++ b/include/deal.II/fe/fe_raviart_thomas.h @@ -129,10 +129,10 @@ public: const unsigned int face_index) const; virtual void interpolate(std::vector &local_dofs, - const std::vector &values) const; + const std::vector &values) const; virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; @@ -263,7 +263,7 @@ public: const std::vector &values) const; virtual void interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset = 0) const; + const unsigned int offset = 0) const; virtual void interpolate( std::vector &local_dofs, const VectorSlice > > &values) const; diff --git a/source/fe/fe_abf.cc b/source/fe/fe_abf.cc index 97d04e44e6..eb95d35e72 100644 --- a/source/fe/fe_abf.cc +++ b/source/fe/fe_abf.cc @@ -524,7 +524,7 @@ void FE_ABF::interpolate( std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { Assert (values.size() == this->generalized_support_points.size(), ExcDimensionMismatch(values.size(), this->generalized_support_points.size())); diff --git a/source/fe/fe_nedelec.cc b/source/fe/fe_nedelec.cc index 85cbc3a981..f093b71614 100644 --- a/source/fe/fe_nedelec.cc +++ b/source/fe/fe_nedelec.cc @@ -3105,7 +3105,7 @@ template void FE_Nedelec::interpolate (std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { const unsigned int deg = this->degree-1; diff --git a/source/fe/fe_q_bubbles.cc b/source/fe/fe_q_bubbles.cc index a7a7e6b86c..9f73b611a0 100644 --- a/source/fe/fe_q_bubbles.cc +++ b/source/fe/fe_q_bubbles.cc @@ -355,7 +355,7 @@ template void FE_Q_Bubbles::interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { Assert (values.size() == this->unit_support_points.size(), ExcDimensionMismatch(values.size(), diff --git a/source/fe/fe_q_dg0.cc b/source/fe/fe_q_dg0.cc index 4e0fe23ab3..e9344f2c5d 100644 --- a/source/fe/fe_q_dg0.cc +++ b/source/fe/fe_q_dg0.cc @@ -199,7 +199,7 @@ template void FE_Q_DG0::interpolate(std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { Assert (values.size() == this->unit_support_points.size(), ExcDimensionMismatch(values.size(), diff --git a/source/fe/fe_rannacher_turek.cc b/source/fe/fe_rannacher_turek.cc index 9b5dbdaa48..034d8eeb03 100644 --- a/source/fe/fe_rannacher_turek.cc +++ b/source/fe/fe_rannacher_turek.cc @@ -133,7 +133,7 @@ template void FE_RannacherTurek::interpolate( std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { AssertDimension(values.size(), this->generalized_support_points.size()); AssertDimension(local_dofs.size(), this->dofs_per_cell); diff --git a/source/fe/fe_raviart_thomas.cc b/source/fe/fe_raviart_thomas.cc index e21f8db1ed..8ecaf65c31 100644 --- a/source/fe/fe_raviart_thomas.cc +++ b/source/fe/fe_raviart_thomas.cc @@ -477,7 +477,7 @@ void FE_RaviartThomas::interpolate( std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { Assert (values.size() == this->generalized_support_points.size(), ExcDimensionMismatch(values.size(), this->generalized_support_points.size())); diff --git a/source/fe/fe_raviart_thomas_nodal.cc b/source/fe/fe_raviart_thomas_nodal.cc index 6b9a1e1bc1..db2bc592fe 100644 --- a/source/fe/fe_raviart_thomas_nodal.cc +++ b/source/fe/fe_raviart_thomas_nodal.cc @@ -295,7 +295,7 @@ void FE_RaviartThomasNodal::interpolate( std::vector &local_dofs, const std::vector > &values, - unsigned int offset) const + const unsigned int offset) const { Assert (values.size() == this->generalized_support_points.size(), ExcDimensionMismatch(values.size(), this->generalized_support_points.size())); -- 2.39.5