From 11b492e993f4272d86fc4019014b47b09a57a2ce Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Wed, 14 Dec 2016 17:53:47 +0100 Subject: bug #1358: fix compilation for sparse += sparse.selfadjointView(); --- test/sparse_basic.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'test/sparse_basic.cpp') diff --git a/test/sparse_basic.cpp b/test/sparse_basic.cpp index 2a3117b2b..4d864bbd0 100644 --- a/test/sparse_basic.cpp +++ b/test/sparse_basic.cpp @@ -431,6 +431,14 @@ template void sparse_basic(const SparseMatrixType& re m3 = m2.template selfadjointView(); VERIFY_IS_APPROX(m3, refMat3); + refMat3 += refMat2.template selfadjointView(); + m3 += m2.template selfadjointView(); + VERIFY_IS_APPROX(m3, refMat3); + + refMat3 -= refMat2.template selfadjointView(); + m3 -= m2.template selfadjointView(); + VERIFY_IS_APPROX(m3, refMat3); + // selfadjointView only works for square matrices: SparseMatrixType m4(rows, rows+1); VERIFY_RAISES_ASSERT(m4.template selfadjointView()); -- cgit v1.2.3