]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fixing the issue with clang 4.0.1 8401/head
authorReza Rastak <rastak@stanford.edu>
Sun, 21 Jul 2019 18:02:19 +0000 (11:02 -0700)
committerReza Rastak <rastak@stanford.edu>
Sun, 21 Jul 2019 18:02:19 +0000 (11:02 -0700)
source/physics/elasticity/standard_tensors.cc

index 463003aa83f85479844e92df75ba2029b51e8bdd..bdae613b9af4bf2d0cba97d8967ae5e4c54b9d36 100644 (file)
 DEAL_II_NAMESPACE_OPEN
 
 #ifndef DOXYGEN
-#  ifndef DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
 
 template <int dim>
-const SymmetricTensor<2, dim>
-  Physics::Elasticity::StandardTensors<dim>::I = unit_symmetric_tensor<dim>();
+DEAL_II_CONSTEXPR const SymmetricTensor<2, dim>
+                        Physics::Elasticity::StandardTensors<dim>::I
+#  ifndef DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
+  = unit_symmetric_tensor<dim>()
+#  endif
+  ;
 
 
 
 template <int dim>
-const SymmetricTensor<4, dim>
-  Physics::Elasticity::StandardTensors<dim>::S = identity_tensor<dim>();
+DEAL_II_CONSTEXPR const SymmetricTensor<4, dim>
+                        Physics::Elasticity::StandardTensors<dim>::S
+#  ifndef DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
+  = identity_tensor<dim>()
+#  endif
+  ;
 
 
 
 template <int dim>
-const SymmetricTensor<4, dim> Physics::Elasticity::StandardTensors<dim>::IxI =
-  outer_product(unit_symmetric_tensor<dim>(), unit_symmetric_tensor<dim>());
+DEAL_II_CONSTEXPR const SymmetricTensor<4, dim>
+                        Physics::Elasticity::StandardTensors<dim>::IxI
+#  ifndef DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
+  = outer_product(unit_symmetric_tensor<dim>(), unit_symmetric_tensor<dim>())
+#  endif
+  ;
 
 
 
 template <int dim>
-const SymmetricTensor<4, dim>
-  Physics::Elasticity::StandardTensors<dim>::dev_P = deviator_tensor<dim>();
+DEAL_II_CONSTEXPR const SymmetricTensor<4, dim>
+                        Physics::Elasticity::StandardTensors<dim>::dev_P
+#  ifndef DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
+  = deviator_tensor<dim>()
+#  endif
+  ;
 
-#  endif // DEAL_II_HAVE_CXX14_CONSTEXPR_CAN_CALL_NONCONSTEXPR
-#endif   // DOXYGEN
+#endif // DOXYGEN
 
 // explicit instantiations
 #include "standard_tensors.inst"

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.