aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/SelfAdjointView.h
diff options
context:
space:
mode:
authorGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2011-01-26 09:49:06 -0500
committerGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2011-01-26 09:49:06 -0500
commitf88ca0ac79ad67124d1c61d258d243e9f66de22f (patch)
treea26a23ab3822174233c892a17bec884d61ef8960 /Eigen/src/Core/SelfAdjointView.h
parent9a5ded3e1d3201b2bce6da92de44e89140b58611 (diff)
fix the eigen3 part of bug #159 - build issue with selfadjointview
Diffstat (limited to 'Eigen/src/Core/SelfAdjointView.h')
-rw-r--r--Eigen/src/Core/SelfAdjointView.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/Eigen/src/Core/SelfAdjointView.h b/Eigen/src/Core/SelfAdjointView.h
index 92d58b9f8..0e9872bf5 100644
--- a/Eigen/src/Core/SelfAdjointView.h
+++ b/Eigen/src/Core/SelfAdjointView.h
@@ -46,14 +46,14 @@ template<typename MatrixType, unsigned int UpLo>
struct traits<SelfAdjointView<MatrixType, UpLo> > : traits<MatrixType>
{
typedef typename nested<MatrixType>::type MatrixTypeNested;
- typedef typename remove_reference<MatrixTypeNested>::type _MatrixTypeNested;
+ typedef typename remove_all<MatrixTypeNested>::type MatrixTypeNestedCleaned;
typedef MatrixType ExpressionType;
typedef typename MatrixType::PlainObject DenseMatrixType;
enum {
Mode = UpLo | SelfAdjoint,
- Flags = _MatrixTypeNested::Flags & (HereditaryBits)
+ Flags = MatrixTypeNestedCleaned::Flags & (HereditaryBits)
& (~(PacketAccessBit | DirectAccessBit | LinearAccessBit)), // FIXME these flags should be preserved
- CoeffReadCost = _MatrixTypeNested::CoeffReadCost
+ CoeffReadCost = MatrixTypeNestedCleaned::CoeffReadCost
};
};
}
@@ -69,6 +69,8 @@ template<typename MatrixType, unsigned int UpLo> class SelfAdjointView
public:
typedef TriangularBase<SelfAdjointView> Base;
+ typedef typename internal::traits<SelfAdjointView>::MatrixTypeNested MatrixTypeNested;
+ typedef typename internal::traits<SelfAdjointView>::MatrixTypeNestedCleaned MatrixTypeNestedCleaned;
/** \brief The type of coefficients in this matrix */
typedef typename internal::traits<SelfAdjointView>::Scalar Scalar;
@@ -107,10 +109,10 @@ template<typename MatrixType, unsigned int UpLo> class SelfAdjointView
}
/** \internal */
- const MatrixType& _expression() const { return m_matrix; }
+ const MatrixTypeNestedCleaned& _expression() const { return m_matrix; }
- const MatrixType& nestedExpression() const { return m_matrix; }
- MatrixType& nestedExpression() { return const_cast<MatrixType&>(m_matrix); }
+ const MatrixTypeNestedCleaned& nestedExpression() const { return m_matrix; }
+ MatrixTypeNestedCleaned& nestedExpression() { return *const_cast<MatrixTypeNestedCleaned*>(&m_matrix); }
/** Efficient self-adjoint matrix times vector/matrix product */
template<typename OtherDerived>
@@ -197,7 +199,7 @@ template<typename MatrixType, unsigned int UpLo> class SelfAdjointView
#endif
protected:
- const typename MatrixType::Nested m_matrix;
+ const MatrixTypeNested m_matrix;
};