diff options
author | Gael Guennebaud <g.gael@free.fr> | 2015-06-19 14:18:29 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2015-06-19 14:18:29 +0200 |
commit | 3f6aa4cd5d03bd9e6e41d2f997fa7bd9b98bd68e (patch) | |
tree | 901c0f7c9488a7b1922c6a6b5a8163986bb3c232 /Eigen | |
parent | 4a8888dfbc8feee9cb2479eb708b95e16a184e7e (diff) |
Remove useless specializations of evaluator_traits
Diffstat (limited to 'Eigen')
-rw-r--r-- | Eigen/src/Core/CoreEvaluators.h | 10 | ||||
-rw-r--r-- | Eigen/src/Core/PermutationMatrix.h | 26 | ||||
-rw-r--r-- | Eigen/src/Core/Transpositions.h | 30 |
3 files changed, 3 insertions, 63 deletions
diff --git a/Eigen/src/Core/CoreEvaluators.h b/Eigen/src/Core/CoreEvaluators.h index 850877079..a1193019f 100644 --- a/Eigen/src/Core/CoreEvaluators.h +++ b/Eigen/src/Core/CoreEvaluators.h @@ -28,13 +28,9 @@ struct storage_kind_to_evaluator_kind { // It can be Dense, Sparse, Triangular, Diagonal, SelfAdjoint, Band, etc. template<typename StorageKind> struct storage_kind_to_shape; - -template<> struct storage_kind_to_shape<Dense> { typedef DenseShape Shape; }; - - -// FIXME Is this necessary? And why was it not before refactoring??? -template<> struct storage_kind_to_shape<PermutationStorage> { typedef PermutationShape Shape; }; - +template<> struct storage_kind_to_shape<Dense> { typedef DenseShape Shape; }; +template<> struct storage_kind_to_shape<PermutationStorage> { typedef PermutationShape Shape; }; +template<> struct storage_kind_to_shape<TranspositionsStorage> { typedef TranspositionsShape Shape; }; // Evaluators have to be specialized with respect to various criteria such as: // - storage/structure/shape diff --git a/Eigen/src/Core/PermutationMatrix.h b/Eigen/src/Core/PermutationMatrix.h index e8236cbd7..8cf989f2c 100644 --- a/Eigen/src/Core/PermutationMatrix.h +++ b/Eigen/src/Core/PermutationMatrix.h @@ -648,32 +648,6 @@ const PermutationWrapper<const Derived> MatrixBase<Derived>::asPermutation() con } namespace internal { - -// TODO currently a permutation matrix expression has the form PermutationMatrix or PermutationWrapper -// or their transpose; in the future shape should be defined by the expression traits -template<int SizeAtCompileTime, int MaxSizeAtCompileTime, typename IndexType> -struct evaluator_traits<PermutationMatrix<SizeAtCompileTime, MaxSizeAtCompileTime, IndexType> > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef PermutationShape Shape; - static const int AssumeAliasing = 0; -}; - -template<typename IndicesType> -struct evaluator_traits<PermutationWrapper<IndicesType> > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef PermutationShape Shape; - static const int AssumeAliasing = 0; -}; - -template<typename Derived> -struct evaluator_traits<Transpose<PermutationBase<Derived> > > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef PermutationShape Shape; - static const int AssumeAliasing = 0; -}; template<> struct AssignmentKind<DenseShape,PermutationShape> { typedef EigenBase2EigenBase Kind; }; diff --git a/Eigen/src/Core/Transpositions.h b/Eigen/src/Core/Transpositions.h index 65447745f..0296882f6 100644 --- a/Eigen/src/Core/Transpositions.h +++ b/Eigen/src/Core/Transpositions.h @@ -402,36 +402,6 @@ class Transpose<TranspositionsBase<TranspositionsDerived> > const TranspositionType& m_transpositions; }; -namespace internal { - -// TODO currently a Transpositions expression has the form Transpositions or TranspositionsWrapper -// or their transpose; in the future shape should be defined by the expression traits -template<int SizeAtCompileTime, int MaxSizeAtCompileTime, typename IndexType> -struct evaluator_traits<Transpositions<SizeAtCompileTime, MaxSizeAtCompileTime, IndexType> > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef TranspositionsShape Shape; - static const int AssumeAliasing = 0; -}; - -template<typename IndicesType> -struct evaluator_traits<TranspositionsWrapper<IndicesType> > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef TranspositionsShape Shape; - static const int AssumeAliasing = 0; -}; - -template<typename Derived> -struct evaluator_traits<Transpose<TranspositionsBase<Derived> > > -{ - typedef typename storage_kind_to_evaluator_kind<Dense>::Kind Kind; - typedef TranspositionsShape Shape; - static const int AssumeAliasing = 0; -}; - -} // end namespace internal - } // end namespace Eigen #endif // EIGEN_TRANSPOSITIONS_H |