Store light-weight objects in evaluators by value.

This resolves failure in unit test caused by dying temporaries.
This commit is contained in:
Jitse Niesen 2011-05-13 14:05:59 +01:00
parent a34a216e82
commit 9a06055870

View File

@ -440,7 +440,7 @@ struct evaluator_impl<CwiseUnaryView<UnaryOp, ArgType> >
}
protected:
const UnaryOp& m_unaryOp;
const UnaryOp m_unaryOp;
typename evaluator<ArgType>::type m_argImpl;
};
@ -782,7 +782,7 @@ struct evaluator_impl<PartialReduxExpr<ArgType, MemberOp, Direction> >
}
protected:
const XprType& m_expr;
const XprType m_expr;
};
@ -1148,7 +1148,7 @@ struct evaluator_impl<SelfCwiseBinaryOp<BinaryOp, LhsXpr, RhsXpr> >
protected:
typename evaluator<LhsXpr>::type m_argImpl;
const BinaryOp& m_functor;
const BinaryOp m_functor;
};