From 8193ffb3d38b56c9295f204dc57dc6bac74f58aa Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Fri, 18 Nov 2016 10:17:34 +0100 Subject: bug #1343: fix compilation regression in mat+=selfadjoint_view. Generic EigenBase2EigenBase assignment was incomplete. --- Eigen/src/Core/AssignEvaluator.h | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'Eigen/src/Core/AssignEvaluator.h') diff --git a/Eigen/src/Core/AssignEvaluator.h b/Eigen/src/Core/AssignEvaluator.h index ffe1dd0ca..6225bd73d 100644 --- a/Eigen/src/Core/AssignEvaluator.h +++ b/Eigen/src/Core/AssignEvaluator.h @@ -876,6 +876,30 @@ struct Assignment eigen_assert(dst.rows() == src.rows() && dst.cols() == src.cols()); src.evalTo(dst); } + + EIGEN_DEVICE_FUNC + static EIGEN_STRONG_INLINE void run(DstXprType &dst, const SrcXprType &src, const internal::add_assign_op &/*func*/) + { + Index dstRows = src.rows(); + Index dstCols = src.cols(); + if((dst.rows()!=dstRows) || (dst.cols()!=dstCols)) + dst.resize(dstRows, dstCols); + + eigen_assert(dst.rows() == src.rows() && dst.cols() == src.cols()); + src.addTo(dst); + } + + EIGEN_DEVICE_FUNC + static EIGEN_STRONG_INLINE void run(DstXprType &dst, const SrcXprType &src, const internal::sub_assign_op &/*func*/) + { + Index dstRows = src.rows(); + Index dstCols = src.cols(); + if((dst.rows()!=dstRows) || (dst.cols()!=dstCols)) + dst.resize(dstRows, dstCols); + + eigen_assert(dst.rows() == src.rows() && dst.cols() == src.cols()); + src.subTo(dst); + } }; } // namespace internal -- cgit v1.2.3