diff --git a/Common/MathUtils/include/MathUtils/SMatrixGPU.h b/Common/MathUtils/include/MathUtils/SMatrixGPU.h index 8158a93666a92..2e551aac98d24 100644 --- a/Common/MathUtils/include/MathUtils/SMatrixGPU.h +++ b/Common/MathUtils/include/MathUtils/SMatrixGPU.h @@ -340,7 +340,7 @@ class MatRepSymGPU static GPUdi() int off(int i) { - static constexpr auto v = row_offsets_utils::make(off1); + constexpr auto v = row_offsets_utils::make(off1); return v[i]; } @@ -453,7 +453,7 @@ class SMatrixGPU GPUd() SMatrixGPU(const SMatrixGPU& rhs); template GPUd() SMatrixGPU(const Expr& rhs); - template + template GPUd() SMatrixGPU& operator=(const M& rhs); template GPUd() SMatrixGPU& operator=(const Expr& rhs); @@ -518,7 +518,7 @@ class SMatrixGPU R mRep; }; -#ifndef __OPENCL__ // TODO: current C++ for OpenCL 2021 is at C++17, so no concepts. But we don't need this trick for OpenCL anyway, so we can just hide it. +#if !defined(__OPENCL__) && !defined(__METAL__) // TODO: current C++ for OpenCL 2021 and MSL 4.1 are both at C++17, so no concepts. But we don't need this trick there anyway, so we can just hide it. template requires(sizeof(typename X::traits_type::pos_type) != 0) // do not provide a template to fair::Logger, etc... (pos_type is a member type of all std::ostream classes) GPUd() X& operator<<(Y& y, const SMatrixGPU&) @@ -684,8 +684,8 @@ GPUdi() SMatrixGPU& SMatrixGPU::operator=(const Expr } template -template -GPUdi() SMatrixGPU& SMatrixGPU::operator=(const M & rhs) +template +GPUdi() SMatrixGPU& SMatrixGPU::operator=(const M& rhs) { mRep = rhs.mRep; return *this;