]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix instantiations of SymmetricTensor 6719/head
authorDaniel Arndt <daniel.arndt@iwr.uni-heidelberg.de>
Wed, 6 Jun 2018 00:57:47 +0000 (02:57 +0200)
committerDaniel Arndt <daniel.arndt@iwr.uni-heidelberg.de>
Wed, 6 Jun 2018 13:34:14 +0000 (15:34 +0200)
include/deal.II/base/symmetric_tensor.h
source/base/symmetric_tensor.cc

index 6879b34e668692d16cf4d87286fbae4a740ec2de..9ac9040c7f698a97ae333e4a6a56eb9738408cc6 100644 (file)
@@ -578,7 +578,7 @@ public:
    * describe a symmetric tensor. In $d$ space dimensions, this number equals
    * $\frac 12 (d^2+d)$ for symmetric tensors of rank 2.
    */
-  static const unsigned int n_independent_components =
+  static constexpr unsigned int n_independent_components =
     internal::SymmetricTensorAccessors::StorageType<rank_, dim, Number>::
       n_independent_components;
 
index b52698339653282a7a7cd1ae7906cd51cbd81c53..bf74f26e323ea1a44138215eb8ff817c358f03c7 100644 (file)
@@ -30,7 +30,8 @@ template <int rank, int dim, typename Number>
 const unsigned int SymmetricTensor<rank, dim, Number>::dimension;
 
 template <int rank, int dim, typename Number>
-const unsigned int SymmetricTensor<rank, dim, Number>::n_independent_components;
+constexpr unsigned int
+  SymmetricTensor<rank, dim, Number>::n_independent_components;
 
 
 // explicit instantiations

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.