aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/ArrayBase.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2010-08-16 11:07:17 +0200
committerGravatar Gael Guennebaud <g.gael@free.fr>2010-08-16 11:07:17 +0200
commitc625a6a85b8a6a805ee3e3dc5afe8555838415e4 (patch)
treed69a0a072003b77b2536eb2dff893c5118cb8660 /Eigen/src/Core/ArrayBase.h
parent453d54325e020746c00a141712e448dec42c0e2e (diff)
improve compilation error message for array+=matrix and the likes
Diffstat (limited to 'Eigen/src/Core/ArrayBase.h')
-rw-r--r--Eigen/src/Core/ArrayBase.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Eigen/src/Core/ArrayBase.h b/Eigen/src/Core/ArrayBase.h
index 941e39938..c53ea0a4f 100644
--- a/Eigen/src/Core/ArrayBase.h
+++ b/Eigen/src/Core/ArrayBase.h
@@ -167,6 +167,11 @@ template<typename Derived> class ArrayBase
explicit ArrayBase(Index);
ArrayBase(Index,Index);
template<typename OtherDerived> explicit ArrayBase(const ArrayBase<OtherDerived>&);
+ protected:
+ // mixing arrays and matrices is not legal
+ template<typename OtherDerived> Derived& operator+=(const MatrixBase<OtherDerived>& mat);
+ // mixing arrays and matrices is not legal
+ template<typename OtherDerived> Derived& operator-=(const MatrixBase<OtherDerived>& mat);
};
/** replaces \c *this by \c *this - \a other.