diff options
Diffstat (limited to 'Eigen/src/Eigen2Support/Minor.h')
-rw-r--r-- | Eigen/src/Eigen2Support/Minor.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/Eigen/src/Eigen2Support/Minor.h b/Eigen/src/Eigen2Support/Minor.h index 555d1d7f5..a058ac1e0 100644 --- a/Eigen/src/Eigen2Support/Minor.h +++ b/Eigen/src/Eigen2Support/Minor.h @@ -38,12 +38,14 @@ * * \sa MatrixBase::minor() */ + +namespace internal { template<typename MatrixType> -struct ei_traits<Minor<MatrixType> > - : ei_traits<MatrixType> +struct traits<Minor<MatrixType> > + : traits<MatrixType> { - typedef typename ei_nested<MatrixType>::type MatrixTypeNested; - typedef typename ei_unref<MatrixTypeNested>::type _MatrixTypeNested; + typedef typename nested<MatrixType>::type MatrixTypeNested; + typedef typename unref<MatrixTypeNested>::type _MatrixTypeNested; typedef typename MatrixType::StorageKind StorageKind; enum { RowsAtCompileTime = (MatrixType::RowsAtCompileTime != Dynamic) ? @@ -59,6 +61,7 @@ struct ei_traits<Minor<MatrixType> > // where loops are unrolled and the 'if' evaluates at compile time }; }; +} template<typename MatrixType> class Minor : public MatrixBase<Minor<MatrixType> > @@ -72,7 +75,7 @@ template<typename MatrixType> class Minor Index row, Index col) : m_matrix(matrix), m_row(row), m_col(col) { - ei_assert(row >= 0 && row < matrix.rows() + eigen_assert(row >= 0 && row < matrix.rows() && col >= 0 && col < matrix.cols()); } |