From 07c5500d709eb7914bd46a1c4b3629bf42783f1d Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Fri, 19 Sep 2014 09:58:20 +0200 Subject: Introduce a compilation error when using the wrong InnerIterator type. --- Eigen/src/SparseCore/SparseMatrix.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Eigen/src') diff --git a/Eigen/src/SparseCore/SparseMatrix.h b/Eigen/src/SparseCore/SparseMatrix.h index 72368ebf3..9e7124ff2 100644 --- a/Eigen/src/SparseCore/SparseMatrix.h +++ b/Eigen/src/SparseCore/SparseMatrix.h @@ -887,6 +887,11 @@ class SparseMatrix::InnerIterator const Index m_outer; Index m_id; Index m_end; + private: + // If you get here, then you're not using the right InnerIterator type, e.g.: + // SparseMatrix A; + // SparseMatrix::InnerIterator it(A,0); + template InnerIterator(const SparseMatrixBase&,Index outer); }; template -- cgit v1.2.3