diff options
author | Benoit Jacob <jacob.benoit.1@gmail.com> | 2010-08-03 10:38:48 -0400 |
---|---|---|
committer | Benoit Jacob <jacob.benoit.1@gmail.com> | 2010-08-03 10:38:48 -0400 |
commit | d90d7a006f7e9aba7d06013faa305bd527093ff2 (patch) | |
tree | da9cfc1122ad3ef1f4326df9c5c280f22fd55226 /Eigen/src/Core/Reverse.h | |
parent | cc25edd5deebe01324ab80d107005657a568289a (diff) |
fix warnings. The one in Reverse was potentially serious: coeff() methods should return CoeffReturnType, not "Scalar", if the expression is potentially a Lvalue.
Diffstat (limited to 'Eigen/src/Core/Reverse.h')
-rw-r--r-- | Eigen/src/Core/Reverse.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Eigen/src/Core/Reverse.h b/Eigen/src/Core/Reverse.h index 6051f7366..abc44bde6 100644 --- a/Eigen/src/Core/Reverse.h +++ b/Eigen/src/Core/Reverse.h @@ -126,13 +126,13 @@ template<typename MatrixType, int Direction> class Reverse ReverseCol ? m_matrix.cols() - col - 1 : col); } - inline const Scalar coeff(Index row, Index col) const + inline CoeffReturnType coeff(Index row, Index col) const { return m_matrix.coeff(ReverseRow ? m_matrix.rows() - row - 1 : row, ReverseCol ? m_matrix.cols() - col - 1 : col); } - inline const Scalar coeff(Index index) const + inline CoeffReturnType coeff(Index index) const { return m_matrix.coeff(m_matrix.size() - index - 1); } |