From d123717e21d6b0d073b3bf7ef96eae7c0651b3b3 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Mon, 5 Sep 2016 15:26:56 +0200 Subject: [PATCH] Fix for msvc 2012 and older --- Eigen/src/Core/CoreEvaluators.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Eigen/src/Core/CoreEvaluators.h b/Eigen/src/Core/CoreEvaluators.h index 5766b6f9d..9b90543c3 100644 --- a/Eigen/src/Core/CoreEvaluators.h +++ b/Eigen/src/Core/CoreEvaluators.h @@ -373,11 +373,7 @@ struct nullary_wrapper // In this case, i==0 and j is used for the actual iteration. template struct nullary_wrapper - : nullary_wrapper // to get the identity wrapper { - typedef nullary_wrapper base; - using base::operator(); - using base::packetOp; template EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Scalar operator()(const NullaryOp& op, Index i, Index j) const { eigen_assert(i==0 || j==0); @@ -387,6 +383,11 @@ struct nullary_wrapper eigen_assert(i==0 || j==0); return op.template packetOp(i+j); } + + template + EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Scalar operator()(const NullaryOp& op, Index i) const { return op(i); } + template + EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE T packetOp(const NullaryOp& op, Index i) const { return op.template packetOp(i); } }; template