aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen
diff options
context:
space:
mode:
authorGravatar Chen-Pang He <jdh8@ms63.hinet.net>2012-09-23 00:20:19 +0800
committerGravatar Chen-Pang He <jdh8@ms63.hinet.net>2012-09-23 00:20:19 +0800
commit963794b04a68671d08edaddf1185010c5f02a096 (patch)
treeb116decb014981b7dc84bd2a5f2a1a483510a226 /Eigen
parent7e64f78f65db6681e6f71b80fa84c57bbce8200f (diff)
Eliminate unnecessary evaluations
Diffstat (limited to 'Eigen')
-rw-r--r--Eigen/src/Core/MatrixBase.h3
-rw-r--r--Eigen/src/Core/NoAlias.h4
-rw-r--r--Eigen/src/Core/util/ForwardDeclarations.h2
3 files changed, 6 insertions, 3 deletions
diff --git a/Eigen/src/Core/MatrixBase.h b/Eigen/src/Core/MatrixBase.h
index c00c1488c..f138b12d2 100644
--- a/Eigen/src/Core/MatrixBase.h
+++ b/Eigen/src/Core/MatrixBase.h
@@ -162,6 +162,9 @@ template<typename Derived> class MatrixBase
#ifndef EIGEN_PARSED_BY_DOXYGEN
template<typename ProductDerived, typename Lhs, typename Rhs>
Derived& lazyAssign(const ProductBase<ProductDerived, Lhs,Rhs>& other);
+
+ template<typename ProductDerived, typename Lhs, typename Rhs>
+ Derived& lazyAssign(const MatrixPowerProductBase<ProductDerived, Lhs,Rhs>& other);
#endif // not EIGEN_PARSED_BY_DOXYGEN
template<typename OtherDerived>
diff --git a/Eigen/src/Core/NoAlias.h b/Eigen/src/Core/NoAlias.h
index fcf2c479c..ac1396f68 100644
--- a/Eigen/src/Core/NoAlias.h
+++ b/Eigen/src/Core/NoAlias.h
@@ -81,8 +81,8 @@ class NoAlias
EIGEN_STRONG_INLINE ExpressionType& operator-=(const CoeffBasedProduct<Lhs,Rhs,NestingFlags>& other)
{ return m_expression.derived() -= CoeffBasedProduct<Lhs,Rhs,NestByRefBit>(other.lhs(), other.rhs()); }
- template<typename Derived>
- EIGEN_STRONG_INLINE ExpressionType& operator=(const MatrixPowerProductBase<Derived>& other)
+ template<typename Derived, typename Lhs, typename Rhs>
+ EIGEN_STRONG_INLINE ExpressionType& operator=(const MatrixPowerProductBase<Derived,Lhs,Rhs>& other)
{ other.derived().evalTo(m_expression); return m_expression; }
#endif
diff --git a/Eigen/src/Core/util/ForwardDeclarations.h b/Eigen/src/Core/util/ForwardDeclarations.h
index 1a3e14b30..58e1d87dc 100644
--- a/Eigen/src/Core/util/ForwardDeclarations.h
+++ b/Eigen/src/Core/util/ForwardDeclarations.h
@@ -272,7 +272,7 @@ template<typename Derived> class MatrixFunctionReturnValue;
template<typename Derived> class MatrixSquareRootReturnValue;
template<typename Derived> class MatrixLogarithmReturnValue;
template<typename Derived> class MatrixPowerReturnValue;
-template<typename Derived> class MatrixPowerProductBase;
+template<typename Derived, typename Lhs, typename Rhs> class MatrixPowerProductBase;
namespace internal {
template <typename Scalar>