From 128ff9cf0746798e6cfbab24918933cc5f183777 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Thu, 23 Feb 2012 11:38:18 +0100 Subject: [PATCH] declare a ReverseInnerIterator in sparse CwiseBinaryOp. These ReverseInnerIterator should probably be removed anyway since we currently don't have real use cases for them. The only one in TriangularSolver could be advantageously replaced by a binary search. --- Eigen/src/SparseCore/SparseCwiseBinaryOp.h | 1 + Eigen/src/SparseCore/TriangularSolver.h | 1 + 2 files changed, 2 insertions(+) diff --git a/Eigen/src/SparseCore/SparseCwiseBinaryOp.h b/Eigen/src/SparseCore/SparseCwiseBinaryOp.h index 5080292b8..22c227edd 100644 --- a/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +++ b/Eigen/src/SparseCore/SparseCwiseBinaryOp.h @@ -63,6 +63,7 @@ class CwiseBinaryOpImpl { public: class InnerIterator; + class ReverseInnerIterator; typedef CwiseBinaryOp Derived; EIGEN_SPARSE_PUBLIC_INTERFACE(Derived) CwiseBinaryOpImpl() diff --git a/Eigen/src/SparseCore/TriangularSolver.h b/Eigen/src/SparseCore/TriangularSolver.h index 8ed471e45..7f27df726 100644 --- a/Eigen/src/SparseCore/TriangularSolver.h +++ b/Eigen/src/SparseCore/TriangularSolver.h @@ -156,6 +156,7 @@ struct sparse_solve_triangular_selector { if(!(Mode & UnitDiag)) { + // TODO replace this by a binary search. make sure the binary search is safe for partially sorted elements typename Lhs::ReverseInnerIterator it(lhs, i); while(it && it.index()!=i) --it;