From 2a721effe7428ea0e4afaeaab1f3a979ad583309 Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Sun, 6 May 2018 17:25:28 +0200 Subject: [PATCH] Default copy assignement in Tensor for non-Intel compilers --- include/deal.II/base/tensor.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/deal.II/base/tensor.h b/include/deal.II/base/tensor.h index 03c1591688..67fc58dfc3 100644 --- a/include/deal.II/base/tensor.h +++ b/include/deal.II/base/tensor.h @@ -209,10 +209,15 @@ public: template Tensor &operator = (const Tensor<0,dim,OtherNumber> &rhs); +#ifdef __INTEL_COMPILER /** * Assignment from tensors with same underlying scalar type. + * This is needed for ICC15 because it can't generate a suitable + * copy constructor for Sacado::Rad::ADvar types automatically. + * See https://github.com/dealii/dealii/pull/5865. */ Tensor &operator = (const Tensor<0,dim,Number> &rhs); +#endif /** * This operator assigns a scalar to a tensor. This obviously requires @@ -813,6 +818,7 @@ Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Tensor<0,dim,Other } +#ifdef __INTEL_COMPILER template inline Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Tensor<0,dim,Number> &p) @@ -820,6 +826,7 @@ Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Tensor<0,dim,Numbe value = p.value; return *this; } +#endif template -- 2.39.5