diff --git a/Eigen/src/Cholesky/LDLT.h b/Eigen/src/Cholesky/LDLT.h index e2a6ca2b2..f46f7b758 100644 --- a/Eigen/src/Cholesky/LDLT.h +++ b/Eigen/src/Cholesky/LDLT.h @@ -59,7 +59,7 @@ template class LDLT }; typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef typename MatrixType::StorageIndex StorageIndex; typedef Matrix TmpMatrixType; @@ -252,8 +252,7 @@ template<> struct ldlt_inplace using std::abs; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; - typedef typename MatrixType::Index Index; - typedef typename TranspositionType::StorageIndexType IndexType; + typedef typename TranspositionType::StorageIndex IndexType; eigen_assert(mat.rows()==mat.cols()); const Index size = mat.rows(); @@ -343,7 +342,6 @@ template<> struct ldlt_inplace using numext::isfinite; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; - typedef typename MatrixType::Index Index; const Index size = mat.rows(); eigen_assert(mat.cols() == size && w.size()==size); @@ -451,7 +449,7 @@ template template LDLT& LDLT::rankUpdate(const MatrixBase& w, const typename NumTraits::Real& sigma) { - typedef typename TranspositionType::StorageIndexType IndexType; + typedef typename TranspositionType::StorageIndex IndexType; const Index size = w.rows(); if (m_isInitialized) { diff --git a/Eigen/src/Cholesky/LLT.h b/Eigen/src/Cholesky/LLT.h index 5e0cf6c88..629c87161 100644 --- a/Eigen/src/Cholesky/LLT.h +++ b/Eigen/src/Cholesky/LLT.h @@ -59,7 +59,7 @@ template class LLT }; typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef typename MatrixType::StorageIndex StorageIndex; enum { @@ -184,12 +184,11 @@ namespace internal { template struct llt_inplace; template -static typename MatrixType::Index llt_rank_update_lower(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) +static Index llt_rank_update_lower(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) { using std::sqrt; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; - typedef typename MatrixType::Index Index; typedef typename MatrixType::ColXpr ColXpr; typedef typename internal::remove_all::type ColXprCleaned; typedef typename ColXprCleaned::SegmentReturnType ColXprSegment; @@ -258,10 +257,9 @@ template struct llt_inplace { typedef typename NumTraits::Real RealScalar; template - static typename MatrixType::Index unblocked(MatrixType& mat) + static Index unblocked(MatrixType& mat) { using std::sqrt; - typedef typename MatrixType::Index Index; eigen_assert(mat.rows()==mat.cols()); const Index size = mat.rows(); @@ -285,9 +283,8 @@ template struct llt_inplace } template - static typename MatrixType::Index blocked(MatrixType& m) + static Index blocked(MatrixType& m) { - typedef typename MatrixType::Index Index; eigen_assert(m.rows()==m.cols()); Index size = m.rows(); if(size<32) @@ -318,7 +315,7 @@ template struct llt_inplace } template - static typename MatrixType::Index rankUpdate(MatrixType& mat, const VectorType& vec, const RealScalar& sigma) + static Index rankUpdate(MatrixType& mat, const VectorType& vec, const RealScalar& sigma) { return Eigen::internal::llt_rank_update_lower(mat, vec, sigma); } @@ -329,19 +326,19 @@ template struct llt_inplace typedef typename NumTraits::Real RealScalar; template - static EIGEN_STRONG_INLINE typename MatrixType::Index unblocked(MatrixType& mat) + static EIGEN_STRONG_INLINE Index unblocked(MatrixType& mat) { Transpose matt(mat); return llt_inplace::unblocked(matt); } template - static EIGEN_STRONG_INLINE typename MatrixType::Index blocked(MatrixType& mat) + static EIGEN_STRONG_INLINE Index blocked(MatrixType& mat) { Transpose matt(mat); return llt_inplace::blocked(matt); } template - static typename MatrixType::Index rankUpdate(MatrixType& mat, const VectorType& vec, const RealScalar& sigma) + static Index rankUpdate(MatrixType& mat, const VectorType& vec, const RealScalar& sigma) { Transpose matt(mat); return llt_inplace::rankUpdate(matt, vec.conjugate(), sigma); diff --git a/Eigen/src/Cholesky/LLT_MKL.h b/Eigen/src/Cholesky/LLT_MKL.h index 64daa445c..09bf59d43 100644 --- a/Eigen/src/Cholesky/LLT_MKL.h +++ b/Eigen/src/Cholesky/LLT_MKL.h @@ -46,7 +46,7 @@ template struct mkl_llt; template<> struct mkl_llt \ { \ template \ - static inline typename MatrixType::Index potrf(MatrixType& m, char uplo) \ + static inline Index potrf(MatrixType& m, char uplo) \ { \ lapack_int matrix_order; \ lapack_int size, lda, info, StorageOrder; \ @@ -67,23 +67,23 @@ template<> struct mkl_llt \ template<> struct llt_inplace \ { \ template \ - static typename MatrixType::Index blocked(MatrixType& m) \ + static Index blocked(MatrixType& m) \ { \ return mkl_llt::potrf(m, 'L'); \ } \ template \ - static typename MatrixType::Index rankUpdate(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) \ + static Index rankUpdate(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) \ { return Eigen::internal::llt_rank_update_lower(mat, vec, sigma); } \ }; \ template<> struct llt_inplace \ { \ template \ - static typename MatrixType::Index blocked(MatrixType& m) \ + static Index blocked(MatrixType& m) \ { \ return mkl_llt::potrf(m, 'U'); \ } \ template \ - static typename MatrixType::Index rankUpdate(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) \ + static Index rankUpdate(MatrixType& mat, const VectorType& vec, const typename MatrixType::RealScalar& sigma) \ { \ Transpose matt(mat); \ return llt_inplace::rankUpdate(matt, vec.conjugate(), sigma); \ diff --git a/Eigen/src/Core/Assign_MKL.h b/Eigen/src/Core/Assign_MKL.h index 97134ffd7..a7b9e9293 100644 --- a/Eigen/src/Core/Assign_MKL.h +++ b/Eigen/src/Core/Assign_MKL.h @@ -84,7 +84,6 @@ template { typedef typename Derived1::Scalar Scalar; - typedef typename Derived1::Index Index; static inline void run(Derived1& dst, const CwiseUnaryOp& src) { // in case we want to (or have to) skip VML at runtime we can call: diff --git a/Eigen/src/Core/CwiseNullaryOp.h b/Eigen/src/Core/CwiseNullaryOp.h index 05c4fedd0..009fd845d 100644 --- a/Eigen/src/Core/CwiseNullaryOp.h +++ b/Eigen/src/Core/CwiseNullaryOp.h @@ -753,7 +753,6 @@ struct setIdentity_impl template struct setIdentity_impl { - typedef typename Derived::Index Index; EIGEN_DEVICE_FUNC static EIGEN_STRONG_INLINE Derived& run(Derived& m) { diff --git a/Eigen/src/Core/DenseCoeffsBase.h b/Eigen/src/Core/DenseCoeffsBase.h index 569fed956..f08380bed 100644 --- a/Eigen/src/Core/DenseCoeffsBase.h +++ b/Eigen/src/Core/DenseCoeffsBase.h @@ -583,14 +583,14 @@ namespace internal { template struct first_aligned_impl { - static inline typename Derived::Index run(const Derived&) + static inline Index run(const Derived&) { return 0; } }; template struct first_aligned_impl { - static inline typename Derived::Index run(const Derived& m) + static inline Index run(const Derived& m) { return internal::first_aligned(&m.const_cast_derived().coeffRef(0,0), m.size()); } @@ -602,7 +602,7 @@ struct first_aligned_impl * documentation. */ template -static inline typename Derived::Index first_aligned(const Derived& m) +static inline Index first_aligned(const Derived& m) { return first_aligned_impl diff --git a/Eigen/src/Core/GeneralProduct.h b/Eigen/src/Core/GeneralProduct.h index 81750722c..7027130e0 100644 --- a/Eigen/src/Core/GeneralProduct.h +++ b/Eigen/src/Core/GeneralProduct.h @@ -221,7 +221,6 @@ template<> struct gemv_dense_sense_selector template static inline void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; typedef typename Lhs::Scalar LhsScalar; typedef typename Rhs::Scalar RhsScalar; typedef typename Dest::Scalar ResScalar; @@ -298,7 +297,6 @@ template<> struct gemv_dense_sense_selector template static void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; typedef typename Lhs::Scalar LhsScalar; typedef typename Rhs::Scalar RhsScalar; typedef typename Dest::Scalar ResScalar; @@ -352,7 +350,6 @@ template<> struct gemv_dense_sense_selector template static void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; // TODO makes sure dest is sequentially stored in memory, otherwise use a temp const Index size = rhs.rows(); for(Index k=0; k struct gemv_dense_sense_selector template static void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; // TODO makes sure rhs is sequentially stored in memory, otherwise use a temp const Index rows = dest.rows(); for(Index i=0; i > : public traits { typedef traits TraitsBase; - typedef typename PlainObjectType::Index Index; - typedef typename PlainObjectType::Scalar Scalar; enum { InnerStrideAtCompileTime = StrideType::InnerStrideAtCompileTime == 0 ? int(PlainObjectType::InnerStrideAtCompileTime) diff --git a/Eigen/src/Core/MapBase.h b/Eigen/src/Core/MapBase.h index 8dca9796d..acac74aa4 100644 --- a/Eigen/src/Core/MapBase.h +++ b/Eigen/src/Core/MapBase.h @@ -178,7 +178,7 @@ template class MapBase typedef typename Base::Scalar Scalar; typedef typename Base::PacketScalar PacketScalar; - typedef typename Base::Index Index; + typedef typename Base::StorageIndex StorageIndex; typedef typename Base::PointerType PointerType; using Base::derived; diff --git a/Eigen/src/Core/Redux.h b/Eigen/src/Core/Redux.h index f6546917e..1a0a00481 100644 --- a/Eigen/src/Core/Redux.h +++ b/Eigen/src/Core/Redux.h @@ -191,7 +191,6 @@ template struct redux_impl { typedef typename Derived::Scalar Scalar; - typedef typename Derived::Index Index; EIGEN_DEVICE_FUNC static EIGEN_STRONG_INLINE Scalar run(const Derived &mat, const Func& func) { @@ -217,7 +216,6 @@ struct redux_impl { typedef typename Derived::Scalar Scalar; typedef typename packet_traits::type PacketScalar; - typedef typename Derived::Index Index; static Scalar run(const Derived &mat, const Func& func) { @@ -275,7 +273,6 @@ struct redux_impl { typedef typename Derived::Scalar Scalar; typedef typename packet_traits::type PacketScalar; - typedef typename Derived::Index Index; EIGEN_DEVICE_FUNC static Scalar run(const Derived &mat, const Func& func) { @@ -342,7 +339,6 @@ public: typedef _XprType XprType; EIGEN_DEVICE_FUNC explicit redux_evaluator(const XprType &xpr) : m_evaluator(xpr), m_xpr(xpr) {} - typedef typename XprType::Index Index; typedef typename XprType::Scalar Scalar; typedef typename XprType::CoeffReturnType CoeffReturnType; typedef typename XprType::PacketScalar PacketScalar; diff --git a/Eigen/src/Core/SolveTriangular.h b/Eigen/src/Core/SolveTriangular.h index f97048bda..9bac726f7 100644 --- a/Eigen/src/Core/SolveTriangular.h +++ b/Eigen/src/Core/SolveTriangular.h @@ -68,7 +68,7 @@ struct triangular_solver_selector if(!useRhsDirectly) MappedRhs(actualRhs,rhs.size()) = rhs; - triangular_solve_vector ::run(actualLhs.cols(), actualLhs.data(), actualLhs.outerStride(), actualRhs); @@ -82,7 +82,6 @@ template struct triangular_solver_selector { typedef typename Rhs::Scalar Scalar; - typedef typename Rhs::Index Index; typedef blas_traits LhsProductTraits; typedef typename LhsProductTraits::DirectLinearAccessType ActualLhsType; @@ -232,7 +231,6 @@ template struct triangular_solv { typedef typename remove_all::type RhsNestedCleaned; typedef ReturnByValue Base; - typedef typename Base::Index Index; triangular_solve_retval(const TriangularType& tri, const Rhs& rhs) : m_triangularMatrix(tri), m_rhs(rhs) diff --git a/Eigen/src/Core/Transpose.h b/Eigen/src/Core/Transpose.h index 7e41769a3..2c967abca 100644 --- a/Eigen/src/Core/Transpose.h +++ b/Eigen/src/Core/Transpose.h @@ -232,7 +232,6 @@ struct inplace_transpose_selector { // PacketSize x Packet static void run(MatrixType& m) { typedef typename MatrixType::Scalar Scalar; typedef typename internal::packet_traits::type Packet; - typedef typename MatrixType::Index Index; const Index PacketSize = internal::packet_traits::size; const Index Alignment = internal::evaluator::Flags&AlignedBit ? Aligned : Unaligned; PacketBlock A; diff --git a/Eigen/src/Core/Transpositions.h b/Eigen/src/Core/Transpositions.h index 77e7d6f45..e9b54c2ba 100644 --- a/Eigen/src/Core/Transpositions.h +++ b/Eigen/src/Core/Transpositions.h @@ -53,8 +53,8 @@ class TranspositionsBase public: typedef typename Traits::IndicesType IndicesType; - typedef typename IndicesType::Scalar StorageIndexType; - typedef typename IndicesType::Index Index; + typedef typename IndicesType::Scalar StorageIndex; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 Derived& derived() { return *static_cast(this); } const Derived& derived() const { return *static_cast(this); } @@ -82,17 +82,17 @@ class TranspositionsBase inline Index size() const { return indices().size(); } /** Direct access to the underlying index vector */ - inline const StorageIndexType& coeff(Index i) const { return indices().coeff(i); } + inline const StorageIndex& coeff(Index i) const { return indices().coeff(i); } /** Direct access to the underlying index vector */ - inline StorageIndexType& coeffRef(Index i) { return indices().coeffRef(i); } + inline StorageIndex& coeffRef(Index i) { return indices().coeffRef(i); } /** Direct access to the underlying index vector */ - inline const StorageIndexType& operator()(Index i) const { return indices()(i); } + inline const StorageIndex& operator()(Index i) const { return indices()(i); } /** Direct access to the underlying index vector */ - inline StorageIndexType& operator()(Index i) { return indices()(i); } + inline StorageIndex& operator()(Index i) { return indices()(i); } /** Direct access to the underlying index vector */ - inline const StorageIndexType& operator[](Index i) const { return indices()(i); } + inline const StorageIndex& operator[](Index i) const { return indices()(i); } /** Direct access to the underlying index vector */ - inline StorageIndexType& operator[](Index i) { return indices()(i); } + inline StorageIndex& operator[](Index i) { return indices()(i); } /** const version of indices(). */ const IndicesType& indices() const { return derived().indices(); } @@ -108,7 +108,7 @@ class TranspositionsBase /** Sets \c *this to represents an identity transformation */ void setIdentity() { - for(StorageIndexType i = 0; i < indices().size(); ++i) + for(StorageIndex i = 0; i < indices().size(); ++i) coeffRef(i) = i; } @@ -145,26 +145,23 @@ class TranspositionsBase }; namespace internal { -template -struct traits > +template +struct traits > { - typedef Matrix<_StorageIndexType, SizeAtCompileTime, 1, 0, MaxSizeAtCompileTime, 1> IndicesType; - typedef typename IndicesType::Index Index; - typedef _StorageIndexType StorageIndexType; + typedef Matrix<_StorageIndex, SizeAtCompileTime, 1, 0, MaxSizeAtCompileTime, 1> IndicesType; + typedef _StorageIndex StorageIndex; }; } -template -class Transpositions : public TranspositionsBase > +template +class Transpositions : public TranspositionsBase > { typedef internal::traits Traits; public: typedef TranspositionsBase Base; typedef typename Traits::IndicesType IndicesType; - typedef typename IndicesType::Scalar StorageIndexType; - typedef typename IndicesType::Index Index; - + typedef typename IndicesType::Scalar StorageIndex; inline Transpositions() {} @@ -219,32 +216,30 @@ class Transpositions : public TranspositionsBase -struct traits,_PacketAccess> > +template +struct traits,_PacketAccess> > { - typedef Map, _PacketAccess> IndicesType; - typedef typename IndicesType::Index Index; - typedef _StorageIndexType StorageIndexType; + typedef Map, _PacketAccess> IndicesType; + typedef _StorageIndex StorageIndex; }; } -template -class Map,PacketAccess> - : public TranspositionsBase,PacketAccess> > +template +class Map,PacketAccess> + : public TranspositionsBase,PacketAccess> > { typedef internal::traits Traits; public: typedef TranspositionsBase Base; typedef typename Traits::IndicesType IndicesType; - typedef typename IndicesType::Scalar StorageIndexType; - typedef typename IndicesType::Index Index; + typedef typename IndicesType::Scalar StorageIndex; - explicit inline Map(const StorageIndexType* indicesPtr) + explicit inline Map(const StorageIndex* indicesPtr) : m_indices(indicesPtr) {} - inline Map(const StorageIndexType* indicesPtr, Index size) + inline Map(const StorageIndex* indicesPtr, Index size) : m_indices(indicesPtr,size) {} @@ -281,8 +276,7 @@ namespace internal { template struct traits > { - typedef typename _IndicesType::Scalar StorageIndexType; - typedef typename _IndicesType::Index Index; + typedef typename _IndicesType::Scalar StorageIndex; typedef _IndicesType IndicesType; }; } @@ -296,8 +290,7 @@ class TranspositionsWrapper typedef TranspositionsBase Base; typedef typename Traits::IndicesType IndicesType; - typedef typename IndicesType::Scalar StorageIndexType; - typedef typename IndicesType::Index Index; + typedef typename IndicesType::Scalar StorageIndex; explicit inline TranspositionsWrapper(IndicesType& a_indices) : m_indices(a_indices) @@ -370,8 +363,7 @@ struct transposition_matrix_product_retval : public ReturnByValue > { typedef typename remove_all::type MatrixTypeNestedCleaned; - typedef typename TranspositionType::Index Index; - typedef typename TranspositionType::StorageIndexType StorageIndexType; + typedef typename TranspositionType::StorageIndex StorageIndex; transposition_matrix_product_retval(const TranspositionType& tr, const MatrixType& matrix) : m_transpositions(tr), m_matrix(matrix) @@ -383,7 +375,7 @@ struct transposition_matrix_product_retval template inline void evalTo(Dest& dst) const { const Index size = m_transpositions.size(); - StorageIndexType j = 0; + StorageIndex j = 0; if(!(is_same::value && extract_data(dst) == extract_data(m_matrix))) dst = m_matrix; diff --git a/Eigen/src/Core/VectorwiseOp.h b/Eigen/src/Core/VectorwiseOp.h index a626310ec..b3dc0c224 100644 --- a/Eigen/src/Core/VectorwiseOp.h +++ b/Eigen/src/Core/VectorwiseOp.h @@ -159,7 +159,7 @@ template class VectorwiseOp typedef typename ExpressionType::Scalar Scalar; typedef typename ExpressionType::RealScalar RealScalar; - typedef typename ExpressionType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef typename internal::conditional::ret, ExpressionType, ExpressionType&>::type ExpressionTypeNested; typedef typename internal::remove_all::type ExpressionTypeNestedCleaned; diff --git a/Eigen/src/Core/Visitor.h b/Eigen/src/Core/Visitor.h index 02bd4eff3..6b1ecae8b 100644 --- a/Eigen/src/Core/Visitor.h +++ b/Eigen/src/Core/Visitor.h @@ -41,7 +41,6 @@ struct visitor_impl template struct visitor_impl { - typedef typename Derived::Index Index; static inline void run(const Derived& mat, Visitor& visitor) { visitor.init(mat.coeff(0,0), 0, 0); @@ -60,7 +59,6 @@ class visitor_evaluator public: explicit visitor_evaluator(const XprType &xpr) : m_evaluator(xpr), m_xpr(xpr) {} - typedef typename XprType::Index Index; typedef typename XprType::Scalar Scalar; typedef typename XprType::CoeffReturnType CoeffReturnType; @@ -124,7 +122,6 @@ namespace internal { template struct coeff_visitor { - typedef typename Derived::Index Index; typedef typename Derived::Scalar Scalar; Index row, col; Scalar res; @@ -144,7 +141,6 @@ struct coeff_visitor template struct min_coeff_visitor : coeff_visitor { - typedef typename Derived::Index Index; typedef typename Derived::Scalar Scalar; void operator() (const Scalar& value, Index i, Index j) { @@ -172,7 +168,6 @@ struct functor_traits > { template struct max_coeff_visitor : coeff_visitor { - typedef typename Derived::Index Index; typedef typename Derived::Scalar Scalar; void operator() (const Scalar& value, Index i, Index j) { diff --git a/Eigen/src/Core/products/GeneralMatrixMatrix.h b/Eigen/src/Core/products/GeneralMatrixMatrix.h index fd9443cd2..8210ea584 100644 --- a/Eigen/src/Core/products/GeneralMatrixMatrix.h +++ b/Eigen/src/Core/products/GeneralMatrixMatrix.h @@ -386,7 +386,6 @@ struct generic_product_impl : generic_product_impl_base > { typedef typename Product::Scalar Scalar; - typedef typename Product::Index Index; typedef typename Lhs::Scalar LhsScalar; typedef typename Rhs::Scalar RhsScalar; diff --git a/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h b/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h index e55994900..a36eb2fe0 100644 --- a/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h +++ b/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h @@ -198,7 +198,6 @@ struct general_product_to_triangular_selector static void run(MatrixType& mat, const ProductType& prod, const typename MatrixType::Scalar& alpha) { typedef typename MatrixType::Scalar Scalar; - typedef typename MatrixType::Index Index; typedef typename internal::remove_all::type Lhs; typedef internal::blas_traits LhsBlasTraits; @@ -243,8 +242,6 @@ struct general_product_to_triangular_selector { static void run(MatrixType& mat, const ProductType& prod, const typename MatrixType::Scalar& alpha) { - typedef typename MatrixType::Index Index; - typedef typename internal::remove_all::type Lhs; typedef internal::blas_traits LhsBlasTraits; typedef typename LhsBlasTraits::DirectLinearAccessType ActualLhs; diff --git a/Eigen/src/Core/products/SelfadjointMatrixMatrix.h b/Eigen/src/Core/products/SelfadjointMatrixMatrix.h index 4b6316d63..f84f54982 100644 --- a/Eigen/src/Core/products/SelfadjointMatrixMatrix.h +++ b/Eigen/src/Core/products/SelfadjointMatrixMatrix.h @@ -474,7 +474,6 @@ template struct selfadjoint_product_impl { typedef typename Product::Scalar Scalar; - typedef typename Product::Index Index; typedef internal::blas_traits LhsBlasTraits; typedef typename LhsBlasTraits::DirectLinearAccessType ActualLhsType; diff --git a/Eigen/src/Core/products/SelfadjointMatrixVector.h b/Eigen/src/Core/products/SelfadjointMatrixVector.h index 372a44e47..5d6ef9913 100644 --- a/Eigen/src/Core/products/SelfadjointMatrixVector.h +++ b/Eigen/src/Core/products/SelfadjointMatrixVector.h @@ -174,7 +174,6 @@ template struct selfadjoint_product_impl { typedef typename Product::Scalar Scalar; - typedef typename Product::Index Index; typedef internal::blas_traits LhsBlasTraits; typedef typename LhsBlasTraits::DirectLinearAccessType ActualLhsType; diff --git a/Eigen/src/Core/products/SelfadjointProduct.h b/Eigen/src/Core/products/SelfadjointProduct.h index 6ca4ae6c0..2af00058d 100644 --- a/Eigen/src/Core/products/SelfadjointProduct.h +++ b/Eigen/src/Core/products/SelfadjointProduct.h @@ -53,7 +53,6 @@ struct selfadjoint_product_selector static void run(MatrixType& mat, const OtherType& other, const typename MatrixType::Scalar& alpha) { typedef typename MatrixType::Scalar Scalar; - typedef typename MatrixType::Index Index; typedef internal::blas_traits OtherBlasTraits; typedef typename OtherBlasTraits::DirectLinearAccessType ActualOtherType; typedef typename internal::remove_all::type _ActualOtherType; @@ -86,7 +85,6 @@ struct selfadjoint_product_selector static void run(MatrixType& mat, const OtherType& other, const typename MatrixType::Scalar& alpha) { typedef typename MatrixType::Scalar Scalar; - typedef typename MatrixType::Index Index; typedef internal::blas_traits OtherBlasTraits; typedef typename OtherBlasTraits::DirectLinearAccessType ActualOtherType; typedef typename internal::remove_all::type _ActualOtherType; diff --git a/Eigen/src/Core/products/TriangularMatrixMatrix.h b/Eigen/src/Core/products/TriangularMatrixMatrix.h index 60c99dcd2..5f01eb5a8 100644 --- a/Eigen/src/Core/products/TriangularMatrixMatrix.h +++ b/Eigen/src/Core/products/TriangularMatrixMatrix.h @@ -388,7 +388,6 @@ struct triangular_product_impl { template static void run(Dest& dst, const Lhs &a_lhs, const Rhs &a_rhs, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; typedef typename Dest::Scalar Scalar; typedef internal::blas_traits LhsBlasTraits; diff --git a/Eigen/src/Core/products/TriangularMatrixVector.h b/Eigen/src/Core/products/TriangularMatrixVector.h index 4d88a710b..7c014b72a 100644 --- a/Eigen/src/Core/products/TriangularMatrixVector.h +++ b/Eigen/src/Core/products/TriangularMatrixVector.h @@ -206,7 +206,6 @@ template struct trmv_selector template static void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; typedef typename Lhs::Scalar LhsScalar; typedef typename Rhs::Scalar RhsScalar; typedef typename Dest::Scalar ResScalar; @@ -283,7 +282,6 @@ template struct trmv_selector template static void run(const Lhs &lhs, const Rhs &rhs, Dest& dest, const typename Dest::Scalar& alpha) { - typedef typename Dest::Index Index; typedef typename Lhs::Scalar LhsScalar; typedef typename Rhs::Scalar RhsScalar; typedef typename Dest::Scalar ResScalar; diff --git a/Eigen/src/Core/util/Macros.h b/Eigen/src/Core/util/Macros.h index 07923848a..e607cdd12 100644 --- a/Eigen/src/Core/util/Macros.h +++ b/Eigen/src/Core/util/Macros.h @@ -660,7 +660,6 @@ namespace Eigen { #define EIGEN_DENSE_PUBLIC_INTERFACE(Derived) \ EIGEN_GENERIC_PUBLIC_INTERFACE(Derived) \ typedef typename Base::PacketScalar PacketScalar; \ - typedef Eigen::Index Index; \ enum { MaxRowsAtCompileTime = Eigen::internal::traits::MaxRowsAtCompileTime, \ MaxColsAtCompileTime = Eigen::internal::traits::MaxColsAtCompileTime}; \ using Base::derived; \ diff --git a/Eigen/src/Eigenvalues/ComplexEigenSolver.h b/Eigen/src/Eigenvalues/ComplexEigenSolver.h index 25082546e..075a62848 100644 --- a/Eigen/src/Eigenvalues/ComplexEigenSolver.h +++ b/Eigen/src/Eigenvalues/ComplexEigenSolver.h @@ -60,7 +60,7 @@ template class ComplexEigenSolver /** \brief Scalar type for matrices of type #MatrixType. */ typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Complex scalar type for #MatrixType. * diff --git a/Eigen/src/Eigenvalues/ComplexSchur.h b/Eigen/src/Eigenvalues/ComplexSchur.h index a3a5a4649..993ee7e1e 100644 --- a/Eigen/src/Eigenvalues/ComplexSchur.h +++ b/Eigen/src/Eigenvalues/ComplexSchur.h @@ -63,7 +63,7 @@ template class ComplexSchur /** \brief Scalar type for matrices of type \p _MatrixType. */ typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Complex scalar type for \p _MatrixType. * diff --git a/Eigen/src/Eigenvalues/EigenSolver.h b/Eigen/src/Eigenvalues/EigenSolver.h index 9372021ff..a63a42341 100644 --- a/Eigen/src/Eigenvalues/EigenSolver.h +++ b/Eigen/src/Eigenvalues/EigenSolver.h @@ -79,7 +79,7 @@ template class EigenSolver /** \brief Scalar type for matrices of type #MatrixType. */ typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Complex scalar type for #MatrixType. * diff --git a/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h b/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h index c20ea03e6..c9da6740a 100644 --- a/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h +++ b/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h @@ -72,7 +72,7 @@ template class GeneralizedEigenSolver /** \brief Scalar type for matrices of type #MatrixType. */ typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Complex scalar type for #MatrixType. * diff --git a/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h b/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h index 1ce1f5f58..5f6bb8289 100644 --- a/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h +++ b/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h @@ -50,7 +50,6 @@ class GeneralizedSelfAdjointEigenSolver : public SelfAdjointEigenSolver<_MatrixT typedef SelfAdjointEigenSolver<_MatrixType> Base; public: - typedef typename Base::Index Index; typedef _MatrixType MatrixType; /** \brief Default constructor for fixed-size matrices. diff --git a/Eigen/src/Eigenvalues/HessenbergDecomposition.h b/Eigen/src/Eigenvalues/HessenbergDecomposition.h index 2615a9f23..87a5bcb69 100644 --- a/Eigen/src/Eigenvalues/HessenbergDecomposition.h +++ b/Eigen/src/Eigenvalues/HessenbergDecomposition.h @@ -71,7 +71,7 @@ template class HessenbergDecomposition /** \brief Scalar type for matrices of type #MatrixType. */ typedef typename MatrixType::Scalar Scalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Type for vector of Householder coefficients. * @@ -337,7 +337,6 @@ namespace internal { template struct HessenbergDecompositionMatrixHReturnType : public ReturnByValue > { - typedef typename MatrixType::Index Index; public: /** \brief Constructor. * diff --git a/Eigen/src/Eigenvalues/RealQZ.h b/Eigen/src/Eigenvalues/RealQZ.h index 128ef9028..ca75f2f50 100644 --- a/Eigen/src/Eigenvalues/RealQZ.h +++ b/Eigen/src/Eigenvalues/RealQZ.h @@ -67,7 +67,7 @@ namespace Eigen { }; typedef typename MatrixType::Scalar Scalar; typedef std::complex::Real> ComplexScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef Matrix EigenvalueType; typedef Matrix ColumnVectorType; @@ -276,7 +276,7 @@ namespace Eigen { /** \internal Look for single small sub-diagonal element S(res, res-1) and return res (or 0) */ template - inline typename MatrixType::Index RealQZ::findSmallSubdiagEntry(Index iu) + inline Index RealQZ::findSmallSubdiagEntry(Index iu) { using std::abs; Index res = iu; @@ -294,7 +294,7 @@ namespace Eigen { /** \internal Look for single small diagonal element T(res, res) for res between f and l, and return res (or f-1) */ template - inline typename MatrixType::Index RealQZ::findSmallDiagEntry(Index f, Index l) + inline Index RealQZ::findSmallDiagEntry(Index f, Index l) { using std::abs; Index res = l; diff --git a/Eigen/src/Eigenvalues/RealSchur.h b/Eigen/src/Eigenvalues/RealSchur.h index 51e61ba38..60ade50a0 100644 --- a/Eigen/src/Eigenvalues/RealSchur.h +++ b/Eigen/src/Eigenvalues/RealSchur.h @@ -64,7 +64,7 @@ template class RealSchur }; typedef typename MatrixType::Scalar Scalar; typedef std::complex::Real> ComplexScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef Matrix EigenvalueType; typedef Matrix ColumnVectorType; @@ -343,7 +343,7 @@ inline typename MatrixType::Scalar RealSchur::computeNormOfT() /** \internal Look for single small sub-diagonal element and returns its index */ template -inline typename MatrixType::Index RealSchur::findSmallSubdiagEntry(Index iu) +inline Index RealSchur::findSmallSubdiagEntry(Index iu) { using std::abs; Index res = iu; diff --git a/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h b/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h index 54f60b197..66d1154cf 100644 --- a/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h +++ b/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h @@ -21,7 +21,7 @@ class GeneralizedSelfAdjointEigenSolver; namespace internal { template struct direct_selfadjoint_eigenvalues; template -ComputationInfo computeFromTridiagonal_impl(DiagType& diag, SubDiagType& subdiag, const typename MatrixType::Index maxIterations, bool computeEigenvectors, MatrixType& eivec); +ComputationInfo computeFromTridiagonal_impl(DiagType& diag, SubDiagType& subdiag, const Index maxIterations, bool computeEigenvectors, MatrixType& eivec); } /** \eigenvalues_module \ingroup Eigenvalues_Module @@ -81,7 +81,7 @@ template class SelfAdjointEigenSolver /** \brief Scalar type for matrices of type \p _MatrixType. */ typedef typename MatrixType::Scalar Scalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** \brief Real scalar type for \p _MatrixType. * @@ -456,12 +456,11 @@ namespace internal { * \returns \c Success or \c NoConvergence */ template -ComputationInfo computeFromTridiagonal_impl(DiagType& diag, SubDiagType& subdiag, const typename MatrixType::Index maxIterations, bool computeEigenvectors, MatrixType& eivec) +ComputationInfo computeFromTridiagonal_impl(DiagType& diag, SubDiagType& subdiag, const Index maxIterations, bool computeEigenvectors, MatrixType& eivec) { using std::abs; ComputationInfo info; - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; Index n = diag.size(); diff --git a/Eigen/src/Eigenvalues/Tridiagonalization.h b/Eigen/src/Eigenvalues/Tridiagonalization.h index bedd1cb34..a6fb00b21 100644 --- a/Eigen/src/Eigenvalues/Tridiagonalization.h +++ b/Eigen/src/Eigenvalues/Tridiagonalization.h @@ -69,7 +69,7 @@ template class Tridiagonalization typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 enum { Size = MatrixType::RowsAtCompileTime, @@ -345,7 +345,6 @@ template void tridiagonalization_inplace(MatrixType& matA, CoeffVectorType& hCoeffs) { using numext::conj; - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; Index n = matA.rows(); @@ -437,7 +436,6 @@ struct tridiagonalization_inplace_selector { typedef typename Tridiagonalization::CoeffVectorType CoeffVectorType; typedef typename Tridiagonalization::HouseholderSequenceType HouseholderSequenceType; - typedef typename MatrixType::Index Index; template static void run(MatrixType& mat, DiagonalType& diag, SubDiagonalType& subdiag, bool extractQ) { @@ -525,7 +523,6 @@ struct tridiagonalization_inplace_selector template struct TridiagonalizationMatrixTReturnType : public ReturnByValue > { - typedef typename MatrixType::Index Index; public: /** \brief Constructor. * diff --git a/Eigen/src/Geometry/Homogeneous.h b/Eigen/src/Geometry/Homogeneous.h index 7f1907542..f16451656 100644 --- a/Eigen/src/Geometry/Homogeneous.h +++ b/Eigen/src/Geometry/Homogeneous.h @@ -238,7 +238,6 @@ struct homogeneous_left_product_impl,Lhs> typedef typename traits::LhsMatrixType LhsMatrixType; typedef typename remove_all::type LhsMatrixTypeCleaned; typedef typename remove_all::type LhsMatrixTypeNested; - typedef typename MatrixType::Index Index; homogeneous_left_product_impl(const Lhs& lhs, const MatrixType& rhs) : m_lhs(take_matrix_for_product::run(lhs)), m_rhs(rhs) @@ -278,7 +277,6 @@ struct homogeneous_right_product_impl,Rhs> : public ReturnByValue,Rhs> > { typedef typename remove_all::type RhsNested; - typedef typename MatrixType::Index Index; homogeneous_right_product_impl(const MatrixType& lhs, const Rhs& rhs) : m_lhs(lhs), m_rhs(rhs) {} diff --git a/Eigen/src/Geometry/OrthoMethods.h b/Eigen/src/Geometry/OrthoMethods.h index a245c79d3..6b2e57392 100644 --- a/Eigen/src/Geometry/OrthoMethods.h +++ b/Eigen/src/Geometry/OrthoMethods.h @@ -133,7 +133,6 @@ struct unitOrthogonal_selector typedef typename plain_matrix_type::type VectorType; typedef typename traits::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename Derived::Index Index; typedef Matrix Vector2; EIGEN_DEVICE_FUNC static inline VectorType run(const Derived& src) diff --git a/Eigen/src/Geometry/Transform.h b/Eigen/src/Geometry/Transform.h index 34d337c90..8c9d7049b 100644 --- a/Eigen/src/Geometry/Transform.h +++ b/Eigen/src/Geometry/Transform.h @@ -205,8 +205,7 @@ public: /** the scalar type of the coefficients */ typedef _Scalar Scalar; typedef Eigen::Index StorageIndex; - /** \deprecated */ - typedef Eigen::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 /** type of the matrix used to represent the transformation */ typedef typename internal::make_proper_matrix_type::type MatrixType; /** constified MatrixType */ diff --git a/Eigen/src/Geometry/Umeyama.h b/Eigen/src/Geometry/Umeyama.h index 5e20662f8..8d9b7a154 100644 --- a/Eigen/src/Geometry/Umeyama.h +++ b/Eigen/src/Geometry/Umeyama.h @@ -97,7 +97,6 @@ umeyama(const MatrixBase& src, const MatrixBase& dst, boo typedef typename internal::umeyama_transform_matrix_type::type TransformationMatrixType; typedef typename internal::traits::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename Derived::Index Index; EIGEN_STATIC_ASSERT(!NumTraits::IsComplex, NUMERIC_TYPE_MUST_BE_REAL) EIGEN_STATIC_ASSERT((internal::is_same::Scalar>::value), diff --git a/Eigen/src/Householder/BlockHouseholder.h b/Eigen/src/Householder/BlockHouseholder.h index 35dbf80a1..39bf8c83d 100644 --- a/Eigen/src/Householder/BlockHouseholder.h +++ b/Eigen/src/Householder/BlockHouseholder.h @@ -21,7 +21,6 @@ namespace internal { // template // void make_block_householder_triangular_factor(TriangularFactorType& triFactor, const VectorsType& vectors, const CoeffsType& hCoeffs) // { -// typedef typename TriangularFactorType::Index Index; // typedef typename VectorsType::Scalar Scalar; // const Index nbVecs = vectors.cols(); // eigen_assert(triFactor.rows() == nbVecs && triFactor.cols() == nbVecs && vectors.rows()>=nbVecs); @@ -51,7 +50,6 @@ namespace internal { template void make_block_householder_triangular_factor(TriangularFactorType& triFactor, const VectorsType& vectors, const CoeffsType& hCoeffs) { - typedef typename TriangularFactorType::Index Index; const Index nbVecs = vectors.cols(); eigen_assert(triFactor.rows() == nbVecs && triFactor.cols() == nbVecs && vectors.rows()>=nbVecs); @@ -80,7 +78,6 @@ void make_block_householder_triangular_factor(TriangularFactorType& triFactor, c template void apply_block_householder_on_the_left(MatrixType& mat, const VectorsType& vectors, const CoeffsType& hCoeffs, bool forward) { - typedef typename MatrixType::Index Index; enum { TFactorSize = MatrixType::ColsAtCompileTime }; Index nbVecs = vectors.cols(); Matrix T(nbVecs,nbVecs); diff --git a/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h b/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h index 251c6fa1a..ef7efc9cf 100644 --- a/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h +++ b/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h @@ -41,7 +41,6 @@ template class SolveWithGuess : public internal::generic_xpr_base, MatrixXpr, typename internal::traits::StorageKind>::type { public: - typedef typename RhsType::Index Index; typedef typename internal::traits::Scalar Scalar; typedef typename internal::traits::PlainObject PlainObject; typedef typename internal::generic_xpr_base, MatrixXpr, typename internal::traits::StorageKind>::type Base; diff --git a/Eigen/src/Jacobi/Jacobi.h b/Eigen/src/Jacobi/Jacobi.h index da9fb53d0..25eabe984 100644 --- a/Eigen/src/Jacobi/Jacobi.h +++ b/Eigen/src/Jacobi/Jacobi.h @@ -62,7 +62,7 @@ template class JacobiRotation JacobiRotation adjoint() const { using numext::conj; return JacobiRotation(conj(m_c), -m_s); } template - bool makeJacobi(const MatrixBase&, typename Derived::Index p, typename Derived::Index q); + bool makeJacobi(const MatrixBase&, Index p, Index q); bool makeJacobi(const RealScalar& x, const Scalar& y, const RealScalar& z); void makeGivens(const Scalar& p, const Scalar& q, Scalar* z=0); @@ -123,7 +123,7 @@ bool JacobiRotation::makeJacobi(const RealScalar& x, const Scalar& y, co */ template template -inline bool JacobiRotation::makeJacobi(const MatrixBase& m, typename Derived::Index p, typename Derived::Index q) +inline bool JacobiRotation::makeJacobi(const MatrixBase& m, Index p, Index q) { return makeJacobi(numext::real(m.coeff(p,p)), m.coeff(p,q), numext::real(m.coeff(q,q))); } @@ -300,7 +300,6 @@ namespace internal { template void /*EIGEN_DONT_INLINE*/ apply_rotation_in_the_plane(VectorX& _x, VectorY& _y, const JacobiRotation& j) { - typedef typename VectorX::Index Index; typedef typename VectorX::Scalar Scalar; enum { PacketSize = packet_traits::size }; typedef typename packet_traits::type Packet; diff --git a/Eigen/src/LU/PartialPivLU.h b/Eigen/src/LU/PartialPivLU.h index 43c2a716e..e57b36bc5 100644 --- a/Eigen/src/LU/PartialPivLU.h +++ b/Eigen/src/LU/PartialPivLU.h @@ -262,7 +262,6 @@ struct partial_lu_impl typedef Block MatrixType; typedef Block BlockType; typedef typename MatrixType::RealScalar RealScalar; - typedef typename MatrixType::Index Index; /** \internal performs the LU decomposition in-place of the matrix \a lu * using an unblocked algorithm. @@ -409,13 +408,13 @@ struct partial_lu_impl /** \internal performs the LU decomposition with partial pivoting in-place. */ template -void partial_lu_inplace(MatrixType& lu, TranspositionType& row_transpositions, typename TranspositionType::StorageIndexType& nb_transpositions) +void partial_lu_inplace(MatrixType& lu, TranspositionType& row_transpositions, typename TranspositionType::StorageIndex& nb_transpositions) { eigen_assert(lu.cols() == row_transpositions.size()); eigen_assert((&row_transpositions.coeffRef(1)-&row_transpositions.coeffRef(0)) == 1); partial_lu_impl - + ::blocked_lu(lu.rows(), lu.cols(), &lu.coeffRef(0,0), lu.outerStride(), &row_transpositions.coeffRef(0), nb_transpositions); } @@ -434,7 +433,7 @@ PartialPivLU& PartialPivLU::compute(const MatrixType& ma m_rowsTranspositions.resize(size); - typename TranspositionType::StorageIndexType nb_transpositions; + typename TranspositionType::StorageIndex nb_transpositions; internal::partial_lu_inplace(m_lu, m_rowsTranspositions, nb_transpositions); m_det_p = (nb_transpositions%2) ? -1 : 1; diff --git a/Eigen/src/QR/FullPivHouseholderQR.h b/Eigen/src/QR/FullPivHouseholderQR.h index a7a0d9138..7d5e58d2f 100644 --- a/Eigen/src/QR/FullPivHouseholderQR.h +++ b/Eigen/src/QR/FullPivHouseholderQR.h @@ -557,7 +557,6 @@ template struct FullPivHouseholderQRMatrixQReturnType : public ReturnByValue > { public: - typedef typename MatrixType::Index Index; typedef typename FullPivHouseholderQR::IntDiagSizeVectorType IntDiagSizeVectorType; typedef typename internal::plain_diag_type::type HCoeffsType; typedef Matrix void householder_qr_inplace_unblocked(MatrixQR& mat, HCoeffs& hCoeffs, typename MatrixQR::Scalar* tempData = 0) { - typedef typename MatrixQR::Index Index; typedef typename MatrixQR::Scalar Scalar; typedef typename MatrixQR::RealScalar RealScalar; Index rows = mat.rows(); @@ -264,11 +263,9 @@ template BlockType; diff --git a/Eigen/src/QR/HouseholderQR_MKL.h b/Eigen/src/QR/HouseholderQR_MKL.h index 8a3a7e406..84ab640a1 100644 --- a/Eigen/src/QR/HouseholderQR_MKL.h +++ b/Eigen/src/QR/HouseholderQR_MKL.h @@ -46,8 +46,7 @@ namespace internal { template \ struct householder_qr_inplace_blocked \ { \ - static void run(MatrixQR& mat, HCoeffs& hCoeffs, \ - typename MatrixQR::Index = 32, \ + static void run(MatrixQR& mat, HCoeffs& hCoeffs, Index = 32, \ typename MatrixQR::Scalar* = 0) \ { \ lapack_int m = (lapack_int) mat.rows(); \ diff --git a/Eigen/src/SVD/BDCSVD.h b/Eigen/src/SVD/BDCSVD.h index dad59bcca..3fe17b27f 100644 --- a/Eigen/src/SVD/BDCSVD.h +++ b/Eigen/src/SVD/BDCSVD.h @@ -65,7 +65,6 @@ public: typedef _MatrixType MatrixType; typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; enum { RowsAtCompileTime = MatrixType::RowsAtCompileTime, ColsAtCompileTime = MatrixType::ColsAtCompileTime, diff --git a/Eigen/src/SVD/JacobiSVD.h b/Eigen/src/SVD/JacobiSVD.h index 444187ae7..fcf01f518 100644 --- a/Eigen/src/SVD/JacobiSVD.h +++ b/Eigen/src/SVD/JacobiSVD.h @@ -52,7 +52,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; void allocate(const JacobiSVD&) {} bool run(JacobiSVD&, const MatrixType&) { @@ -66,7 +65,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; enum { @@ -107,7 +105,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; enum { @@ -157,8 +154,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; - void allocate(const JacobiSVD& svd) { if (svd.rows() != m_qr.rows() || svd.cols() != m_qr.cols()) @@ -198,7 +193,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; enum { @@ -257,8 +251,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; - void allocate(const JacobiSVD& svd) { if (svd.rows() != m_qr.rows() || svd.cols() != m_qr.cols()) @@ -297,7 +289,6 @@ template class qr_preconditioner_impl { public: - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; enum { @@ -359,7 +350,6 @@ template struct svd_precondition_2x2_block_to_be_real { typedef JacobiSVD SVD; - typedef typename SVD::Index Index; static void run(typename SVD::WorkMatrixType&, SVD&, Index, Index) {} }; @@ -369,7 +359,6 @@ struct svd_precondition_2x2_block_to_be_real typedef JacobiSVD SVD; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; - typedef typename SVD::Index Index; static void run(typename SVD::WorkMatrixType& work_matrix, SVD& svd, Index p, Index q) { using std::sqrt; @@ -514,7 +503,6 @@ template class JacobiSVD typedef _MatrixType MatrixType; typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; - typedef typename MatrixType::Index Index; enum { RowsAtCompileTime = MatrixType::RowsAtCompileTime, ColsAtCompileTime = MatrixType::ColsAtCompileTime, diff --git a/Eigen/src/SVD/SVDBase.h b/Eigen/src/SVD/SVDBase.h index 95d378da9..8903755e7 100644 --- a/Eigen/src/SVD/SVDBase.h +++ b/Eigen/src/SVD/SVDBase.h @@ -53,6 +53,7 @@ public: typedef typename MatrixType::Scalar Scalar; typedef typename NumTraits::Real RealScalar; typedef typename MatrixType::StorageIndex StorageIndex; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 enum { RowsAtCompileTime = MatrixType::RowsAtCompileTime, ColsAtCompileTime = MatrixType::ColsAtCompileTime, diff --git a/Eigen/src/SVD/UpperBidiagonalization.h b/Eigen/src/SVD/UpperBidiagonalization.h index eaa6bb86e..9dc470fd9 100644 --- a/Eigen/src/SVD/UpperBidiagonalization.h +++ b/Eigen/src/SVD/UpperBidiagonalization.h @@ -29,7 +29,7 @@ template class UpperBidiagonalization }; typedef typename MatrixType::Scalar Scalar; typedef typename MatrixType::RealScalar RealScalar; - typedef typename MatrixType::Index Index; + typedef Eigen::Index Index; ///< \deprecated since Eigen 3.3 typedef Matrix RowVectorType; typedef Matrix ColVectorType; typedef BandMatrix BidiagonalType; @@ -95,7 +95,6 @@ void upperbidiagonalization_inplace_unblocked(MatrixType& mat, typename MatrixType::RealScalar *upper_diagonal, typename MatrixType::Scalar* tempData = 0) { - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; Index rows = mat.rows(); @@ -153,13 +152,12 @@ template void upperbidiagonalization_blocked_helper(MatrixType& A, typename MatrixType::RealScalar *diagonal, typename MatrixType::RealScalar *upper_diagonal, - typename MatrixType::Index bs, + Index bs, Ref::Flags & RowMajorBit> > X, Ref::Flags & RowMajorBit> > Y) { - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; enum { StorageOrder = traits::Flags & RowMajorBit }; typedef InnerStride ColInnerStride; @@ -282,10 +280,9 @@ void upperbidiagonalization_blocked_helper(MatrixType& A, */ template void upperbidiagonalization_inplace_blocked(MatrixType& A, BidiagType& bidiagonal, - typename MatrixType::Index maxBlockSize=32, + Index maxBlockSize=32, typename MatrixType::Scalar* /*tempData*/ = 0) { - typedef typename MatrixType::Index Index; typedef typename MatrixType::Scalar Scalar; typedef Block BlockType; diff --git a/Eigen/src/SparseCore/SparseBlock.h b/Eigen/src/SparseCore/SparseBlock.h index b8604a219..40dc1a2bd 100644 --- a/Eigen/src/SparseCore/SparseBlock.h +++ b/Eigen/src/SparseCore/SparseBlock.h @@ -158,7 +158,7 @@ public: matrix.outerIndexPtr()[m_outerStart+k] = p; p += tmp.innerVector(k).nonZeros(); } - std::ptrdiff_t offset = nnz - block_size; + StorageIndex offset = internal::convert_index(nnz - block_size); for(Index k = m_outerStart + m_outerSize.value(); k<=matrix.outerSize(); ++k) { matrix.outerIndexPtr()[k] += offset; diff --git a/Eigen/src/SparseCore/SparseView.h b/Eigen/src/SparseCore/SparseView.h index d6042d970..1c69aa458 100644 --- a/Eigen/src/SparseCore/SparseView.h +++ b/Eigen/src/SparseCore/SparseView.h @@ -78,7 +78,7 @@ struct unary_evaluator, IteratorBased> typedef typename XprType::Scalar Scalar; public: - EIGEN_STRONG_INLINE InnerIterator(const unary_evaluator& sve, typename XprType::Index outer) + EIGEN_STRONG_INLINE InnerIterator(const unary_evaluator& sve, Index outer) : EvalIterator(sve.m_argImpl,outer), m_view(sve.m_view) { incrementToNonZero(); @@ -126,7 +126,6 @@ struct unary_evaluator, IndexBased> typedef SparseView XprType; protected: enum { IsRowMajor = (XprType::Flags&RowMajorBit)==RowMajorBit }; - typedef typename XprType::StorageIndex StorageIndex; typedef typename XprType::Scalar Scalar; public: diff --git a/Eigen/src/SuperLUSupport/SuperLUSupport.h b/Eigen/src/SuperLUSupport/SuperLUSupport.h index 8779eb74c..d182b59b3 100644 --- a/Eigen/src/SuperLUSupport/SuperLUSupport.h +++ b/Eigen/src/SuperLUSupport/SuperLUSupport.h @@ -808,7 +808,6 @@ class SuperILU : public SuperLUBase<_MatrixType,SuperILU<_MatrixType> > typedef _MatrixType MatrixType; typedef typename Base::Scalar Scalar; typedef typename Base::RealScalar RealScalar; - typedef typename Base::Index Index; public: using Base::_solve_impl; diff --git a/Eigen/src/misc/Image.h b/Eigen/src/misc/Image.h index 75c5f433a..b8b8a0455 100644 --- a/Eigen/src/misc/Image.h +++ b/Eigen/src/misc/Image.h @@ -38,7 +38,6 @@ template struct image_retval_base typedef _DecompositionType DecompositionType; typedef typename DecompositionType::MatrixType MatrixType; typedef ReturnByValue Base; - typedef typename Base::Index Index; image_retval_base(const DecompositionType& dec, const MatrixType& originalMatrix) : m_dec(dec), m_rank(dec.rank()), @@ -69,7 +68,6 @@ template struct image_retval_base typedef typename DecompositionType::MatrixType MatrixType; \ typedef typename MatrixType::Scalar Scalar; \ typedef typename MatrixType::RealScalar RealScalar; \ - typedef typename MatrixType::Index Index; \ typedef Eigen::internal::image_retval_base Base; \ using Base::dec; \ using Base::originalMatrix; \ diff --git a/Eigen/src/misc/Kernel.h b/Eigen/src/misc/Kernel.h index 4b03e44c1..bef5d6ff5 100644 --- a/Eigen/src/misc/Kernel.h +++ b/Eigen/src/misc/Kernel.h @@ -39,7 +39,6 @@ template struct kernel_retval_base { typedef _DecompositionType DecompositionType; typedef ReturnByValue Base; - typedef typename Base::Index Index; explicit kernel_retval_base(const DecompositionType& dec) : m_dec(dec), @@ -68,7 +67,6 @@ template struct kernel_retval_base typedef typename DecompositionType::MatrixType MatrixType; \ typedef typename MatrixType::Scalar Scalar; \ typedef typename MatrixType::RealScalar RealScalar; \ - typedef typename MatrixType::Index Index; \ typedef Eigen::internal::kernel_retval_base Base; \ using Base::dec; \ using Base::rank; \