mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-12 11:49:02 +08:00
fix SparseMatrix option bit flag in eval<> helper
This commit is contained in:
parent
b648484dba
commit
1b004d5794
@ -113,9 +113,10 @@ template<typename T,int Rows> struct sparse_eval<T,Rows,1> {
|
|||||||
|
|
||||||
template<typename T,int Rows,int Cols> struct sparse_eval {
|
template<typename T,int Rows,int Cols> struct sparse_eval {
|
||||||
typedef typename traits<T>::Scalar _Scalar;
|
typedef typename traits<T>::Scalar _Scalar;
|
||||||
enum { _Flags = traits<T>::Flags };
|
typedef typename traits<T>::Index _Index;
|
||||||
|
enum { _Options = ((traits<T>::Flags&RowMajorBit)==RowMajorBit) ? RowMajor : ColMajor };
|
||||||
public:
|
public:
|
||||||
typedef SparseMatrix<_Scalar, _Flags> type;
|
typedef SparseMatrix<_Scalar, _Options, _Index> type;
|
||||||
};
|
};
|
||||||
|
|
||||||
template<typename T> struct sparse_eval<T,1,1> {
|
template<typename T> struct sparse_eval<T,1,1> {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user