aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/Diagonal.h
diff options
context:
space:
mode:
authorGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-05-17 16:00:56 +0200
committerGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-05-17 16:00:56 +0200
commit934d6b47499d7dc883e4298fcbd94534f0c6ab0f (patch)
tree7d27f37d47fb0b2d82c4d62e163719789b456832 /Eigen/src/Core/Diagonal.h
parent6ea7cbdc8703775a5419bcb003a8d8a29fc3b671 (diff)
fix #2, bug in Diagonal::MaxRowsAtCompileTime when Index==Dynamic
Diffstat (limited to 'Eigen/src/Core/Diagonal.h')
-rw-r--r--Eigen/src/Core/Diagonal.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/Eigen/src/Core/Diagonal.h b/Eigen/src/Core/Diagonal.h
index 90f5c4d89..40da4138c 100644
--- a/Eigen/src/Core/Diagonal.h
+++ b/Eigen/src/Core/Diagonal.h
@@ -55,8 +55,8 @@ struct ei_traits<Diagonal<MatrixType,Index> >
MatrixType::ColsAtCompileTime) - AbsIndex),
ColsAtCompileTime = 1,
MaxRowsAtCompileTime = int(MatrixType::MaxSizeAtCompileTime) == Dynamic ? Dynamic
- : (EIGEN_ENUM_MIN(MatrixType::MaxRowsAtCompileTime,
- MatrixType::MaxColsAtCompileTime) - AbsIndex),
+ : Index == Dynamic ? EIGEN_ENUM_MIN(MatrixType::MaxRowsAtCompileTime, MatrixType::MaxColsAtCompileTime)
+ : (EIGEN_ENUM_MIN(MatrixType::MaxRowsAtCompileTime, MatrixType::MaxColsAtCompileTime) - AbsIndex),
MaxColsAtCompileTime = 1,
Flags = (unsigned int)_MatrixTypeNested::Flags & (HereditaryBits | LinearAccessBit),
CoeffReadCost = _MatrixTypeNested::CoeffReadCost