diff options
author | 2014-09-18 17:31:17 +0200 | |
---|---|---|
committer | 2014-09-18 17:31:17 +0200 | |
commit | 62bce6e5e6da71dd8d85ae229d24b9f9f13d1681 (patch) | |
tree | 9c2bff02dc2e1ae21bbe698b466a74e1d9bb5966 /unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h | |
parent | 060e835ee9f7a3abb9ff3d9f2522027bf2f98efe (diff) |
Make MatrixFunction use nested_eval instead of nested
Diffstat (limited to 'unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h')
-rw-r--r-- | unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h b/unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h index 8ca4f4864..3a4d6eb3f 100644 --- a/unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h +++ b/unsupported/Eigen/src/MatrixFunctions/MatrixSquareRoot.h @@ -320,7 +320,7 @@ template<typename Derived> class MatrixSquareRootReturnValue { protected: typedef typename Derived::Index Index; - typedef typename internal::nested<Derived, 10>::type DerivedNested; + typedef typename internal::nested<Derived>::type DerivedNested; public: /** \brief Constructor. @@ -338,8 +338,10 @@ template<typename Derived> class MatrixSquareRootReturnValue template <typename ResultType> inline void evalTo(ResultType& result) const { - typedef typename internal::remove_all<DerivedNested>::type DerivedNestedClean; - internal::matrix_sqrt_compute<DerivedNestedClean>::run(m_src, result); + typedef typename internal::nested_eval<Derived, 10>::type DerivedEvalType; + typedef typename internal::remove_all<DerivedEvalType>::type DerivedEvalTypeClean; + DerivedEvalType tmp(m_src); + internal::matrix_sqrt_compute<DerivedEvalTypeClean>::run(tmp, result); } Index rows() const { return m_src.rows(); } |