diff options
author | Benoit Jacob <jacob.benoit.1@gmail.com> | 2010-12-09 03:47:35 -0500 |
---|---|---|
committer | Benoit Jacob <jacob.benoit.1@gmail.com> | 2010-12-09 03:47:35 -0500 |
commit | aec07827197cbfa6457c1ef13a66061dc5991ffb (patch) | |
tree | 2ea0a3e3640217001bb9a8d7faa8c35fd239ae42 /Eigen/src/Core/util/StaticAssert.h | |
parent | 1be6449f2e1bd51393a55b06b967f43dc9be6ec6 (diff) |
fix the build of eigensolver_complex test.
it was calling the .value() method on an inner product, and that was blocked in bad zero-sized case.
fixed by adding the .value() method to DenseBase for all 1x1 expressions, and allowing coeff accessors in ProductBase for 1x1 expressions.
Diffstat (limited to 'Eigen/src/Core/util/StaticAssert.h')
-rw-r--r-- | Eigen/src/Core/util/StaticAssert.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Eigen/src/Core/util/StaticAssert.h b/Eigen/src/Core/util/StaticAssert.h index 71e8eef1b..dbdf8b209 100644 --- a/Eigen/src/Core/util/StaticAssert.h +++ b/Eigen/src/Core/util/StaticAssert.h @@ -92,7 +92,8 @@ PACKET_ACCESS_REQUIRES_TO_HAVE_INNER_STRIDE_FIXED_TO_1, THIS_METHOD_IS_ONLY_FOR_SPECIFIC_TRANSFORMATIONS, YOU_CANNOT_MIX_ARRAYS_AND_MATRICES, - YOU_PERFORMED_AN_INVALID_TRANSFORMATION_CONVERSION + YOU_PERFORMED_AN_INVALID_TRANSFORMATION_CONVERSION, + THIS_METHOD_IS_ONLY_FOR_1x1_EXPRESSIONS }; }; @@ -177,4 +178,9 @@ EIGEN_PREDICATE_SAME_MATRIX_SIZE(TYPE0,TYPE1),\ YOU_MIXED_MATRICES_OF_DIFFERENT_SIZES) +#define EIGEN_STATIC_ASSERT_SIZE_1x1(TYPE) \ + EIGEN_STATIC_ASSERT((TYPE::RowsAtCompileTime == 1 || TYPE::RowsAtCompileTime == Dynamic) && \ + (TYPE::ColsAtCompileTime == 1 || TYPE::ColsAtCompileTime == Dynamic), \ + THIS_METHOD_IS_ONLY_FOR_1x1_EXPRESSIONS) + #endif // EIGEN_STATIC_ASSERT_H |