From: Daniel Arndt Date: Fri, 4 May 2018 16:49:55 +0000 (+0200) Subject: Default copy assignement in Tensor for non-Intel compilers X-Git-Tag: v9.0.0-rc2~2^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b509e726018ba3c8689158f0606867664039416e;p=dealii.git Default copy assignement in Tensor for non-Intel compilers --- diff --git a/include/deal.II/base/tensor.h b/include/deal.II/base/tensor.h index 03c1591688..7efa878120 100644 --- a/include/deal.II/base/tensor.h +++ b/include/deal.II/base/tensor.h @@ -212,7 +212,13 @@ public: /** * Assignment from tensors with same underlying scalar type. */ +#ifdef __INTEL_COMPILER Tensor &operator = (const Tensor<0,dim,Number> &rhs); + // ICC 15 doesn't allow this copy constructor to be defaulted. + // see https://github.com/dealii/dealii/pull/5865. +#else + Tensor &operator = (const Tensor<0,dim,Number> &rhs) = default; +#endif /** * This operator assigns a scalar to a tensor. This obviously requires @@ -813,6 +819,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 +827,7 @@ Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Tensor<0,dim,Numbe value = p.value; return *this; } +#endif template