aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/misc/Kernel.h
diff options
context:
space:
mode:
Diffstat (limited to 'Eigen/src/misc/Kernel.h')
-rw-r--r--Eigen/src/misc/Kernel.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/Eigen/src/misc/Kernel.h b/Eigen/src/misc/Kernel.h
index 497b42eab..38a2d4097 100644
--- a/Eigen/src/misc/Kernel.h
+++ b/Eigen/src/misc/Kernel.h
@@ -49,6 +49,8 @@ template<typename _DecompositionType> struct ei_kernel_retval_base
: public ReturnByValue<ei_kernel_retval_base<_DecompositionType> >
{
typedef _DecompositionType DecompositionType;
+ typedef ReturnByValue<ei_kernel_retval_base> Base;
+ typedef typename Base::Index Index;
ei_kernel_retval_base(const DecompositionType& dec)
: m_dec(dec),
@@ -56,9 +58,9 @@ template<typename _DecompositionType> struct ei_kernel_retval_base
m_cols(m_rank==dec.cols() ? 1 : dec.cols() - m_rank)
{}
- inline int rows() const { return m_dec.cols(); }
- inline int cols() const { return m_cols; }
- inline int rank() const { return m_rank; }
+ inline Index rows() const { return m_dec.cols(); }
+ inline Index cols() const { return m_cols; }
+ inline Index rank() const { return m_rank; }
inline const DecompositionType& dec() const { return m_dec; }
template<typename Dest> inline void evalTo(Dest& dst) const
@@ -68,13 +70,14 @@ template<typename _DecompositionType> struct ei_kernel_retval_base
protected:
const DecompositionType& m_dec;
- int m_rank, m_cols;
+ Index m_rank, m_cols;
};
#define EIGEN_MAKE_KERNEL_HELPERS(DecompositionType) \
typedef typename DecompositionType::MatrixType MatrixType; \
typedef typename MatrixType::Scalar Scalar; \
typedef typename MatrixType::RealScalar RealScalar; \
+ typedef typename MatrixType::Index Index; \
typedef ei_kernel_retval_base<DecompositionType> Base; \
using Base::dec; \
using Base::rank; \