much better workaround for empty struct (the previous one caused GCC 4.3 to generate wrong code leading to segfaults)

This commit is contained in:
Gael Guennebaud
2009-12-18 17:08:59 +01:00
parent 945cbc3bc6
commit 9d54783036
5 changed files with 53 additions and 34 deletions

View File

@@ -110,7 +110,8 @@ class PartialReduxExpr : ei_no_assignment_operator,
#define EIGEN_MEMBER_FUNCTOR(MEMBER,COST) \
template <typename ResultType> \
struct ei_member_##MEMBER EIGEN_EMPTY_STRUCT { \
struct ei_member_##MEMBER { \
EIGEN_EMPTY_STRUCT_CTOR(ei_member_##MEMBER) \
typedef ResultType result_type; \
template<typename Scalar, int Size> struct Cost \
{ enum { value = COST }; }; \