From 8456bbbadb8175a9e20d804b61de4da7d951d7f7 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Wed, 18 May 2016 16:53:28 +0200 Subject: bug #1224: fix regression in (dense*dense).sparseView() by specializing evaluator> for sparse products only. --- Eigen/src/SparseCore/SparseProduct.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Eigen/src/SparseCore') diff --git a/Eigen/src/SparseCore/SparseProduct.h b/Eigen/src/SparseCore/SparseProduct.h index cbd0db71b..b23003bb1 100644 --- a/Eigen/src/SparseCore/SparseProduct.h +++ b/Eigen/src/SparseCore/SparseProduct.h @@ -131,14 +131,14 @@ struct Assignment, internal::sub_a }; template -struct evaluator > > +struct unary_evaluator >, IteratorBased> : public evaluator::PlainObject> { typedef SparseView > XprType; typedef typename XprType::PlainObject PlainObject; typedef evaluator Base; - - explicit evaluator(const XprType& xpr) + + explicit unary_evaluator(const XprType& xpr) : m_result(xpr.rows(), xpr.cols()) { using std::abs; @@ -147,13 +147,13 @@ struct evaluator > > typedef typename nested_eval::type RhsNested; LhsNested lhsNested(xpr.nestedExpression().lhs()); RhsNested rhsNested(xpr.nestedExpression().rhs()); - + internal::sparse_sparse_product_with_pruning_selector::type, typename remove_all::type, PlainObject>::run(lhsNested,rhsNested,m_result, abs(xpr.reference())*xpr.epsilon()); } - -protected: + +protected: PlainObject m_result; }; -- cgit v1.2.3