diff options
author | Gael Guennebaud <g.gael@free.fr> | 2018-03-09 10:00:51 +0100 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2018-03-09 10:00:51 +0100 |
commit | f6be7289d703ea608db01bfae1fb41cb93465363 (patch) | |
tree | 7252178a0aaedcabee8a9d3aca7fb4dc7714c9dc /Eigen/src/Core/util/StaticAssert.h | |
parent | d820ab9edc0b38af4cdb3d545714a0c9083e5a78 (diff) |
Implement better static assertion checking to make sure that the first assertion is a static one and not a runtime one.
Diffstat (limited to 'Eigen/src/Core/util/StaticAssert.h')
-rw-r--r-- | Eigen/src/Core/util/StaticAssert.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Eigen/src/Core/util/StaticAssert.h b/Eigen/src/Core/util/StaticAssert.h index 987d5fce4..500e47792 100644 --- a/Eigen/src/Core/util/StaticAssert.h +++ b/Eigen/src/Core/util/StaticAssert.h @@ -24,6 +24,7 @@ * */ +#ifndef EIGEN_STATIC_ASSERT #ifndef EIGEN_NO_STATIC_ASSERT #if EIGEN_MAX_CPP_VER>=11 && (__has_feature(cxx_static_assert) || (defined(__cplusplus) && __cplusplus >= 201103L) || (EIGEN_COMP_MSVC >= 1600)) @@ -132,7 +133,7 @@ #define EIGEN_STATIC_ASSERT(CONDITION,MSG) eigen_assert((CONDITION) && #MSG); #endif // EIGEN_NO_STATIC_ASSERT - +#endif // EIGEN_STATIC_ASSERT // static assertion failing if the type \a TYPE is not a vector type #define EIGEN_STATIC_ASSERT_VECTOR_ONLY(TYPE) \ |