diff options
author | Gael Guennebaud <g.gael@free.fr> | 2008-03-12 18:44:42 +0000 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2008-03-12 18:44:42 +0000 |
commit | 16257d44ddd4e9b6ba883f3233d0364cb46d3396 (patch) | |
tree | 7853ca344d92375f42ee004b28390f7ba4edfe06 | |
parent | 35bce20954581415a9e5057cc24f6e4769ef78f5 (diff) |
fixed an issue with VERIFY_ASSERT
-rw-r--r-- | test/main.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/main.h b/test/main.h index 6ef98b73a..3f68c73eb 100644 --- a/test/main.h +++ b/test/main.h @@ -44,7 +44,11 @@ // This may happen when a second exceptions is raise in a destructor. static bool no_more_assert = false; - struct ei_assert_exception {}; + struct ei_assert_exception + { + ei_assert_exception(void) {} + ~ei_assert_exception() { Eigen::no_more_assert = false; } + }; } #define EI_PP_MAKE_STRING2(S) #S @@ -88,7 +92,7 @@ #define assert(a) if( (!(a)) && (!no_more_assert) ) { \ Eigen::no_more_assert = true; \ - throw Eigen::ei_assert_exception(); \ + throw Eigen::ei_assert_exception(""); \ } #define VERIFY_RAISES_ASSERT(a) {\ |