aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/SparseCore/SparseMatrixBase.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2018-06-08 16:55:10 +0200
committerGravatar Gael Guennebaud <g.gael@free.fr>2018-06-08 16:55:10 +0200
commitd6813fb1c565e0150cad0332b5afa6ac2e1ed286 (patch)
treee1f9025910125d0e3f964b2447f4fb00eac7aef9 /Eigen/src/SparseCore/SparseMatrixBase.h
parent89d65bb9d6ed8ebc9ce297a3fad90d78ba6cbbbb (diff)
bug #1531: expose NumDimensions for solve and sparse expressions.
Diffstat (limited to 'Eigen/src/SparseCore/SparseMatrixBase.h')
-rw-r--r--Eigen/src/SparseCore/SparseMatrixBase.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Eigen/src/SparseCore/SparseMatrixBase.h b/Eigen/src/SparseCore/SparseMatrixBase.h
index dac2d8c62..229449f02 100644
--- a/Eigen/src/SparseCore/SparseMatrixBase.h
+++ b/Eigen/src/SparseCore/SparseMatrixBase.h
@@ -87,6 +87,11 @@ template<typename Derived> class SparseMatrixBase
* we are dealing with a column-vector (if there is only one column) or with
* a row-vector (if there is only one row). */
+ NumDimensions = int(MaxSizeAtCompileTime) == 1 ? 0 : bool(IsVectorAtCompileTime) ? 1 : 2,
+ /**< This value is equal to Tensor::NumDimensions, i.e. 0 for scalars, 1 for vectors,
+ * and 2 for matrices.
+ */
+
Flags = internal::traits<Derived>::Flags,
/**< This stores expression \ref flags flags which may or may not be inherited by new expressions
* constructed from this one. See the \ref flags "list of flags".