Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Fixes for cygwin

Commit
5713381d060e94647d110227e2943c0aa9951401
Author
philsquared ·
Parents
1ab6be30a28b

Files · Download .tar.gz

Changes

 include/internal/catch_debugger.h          | 5 ++++-
 include/internal/catch_fatal_condition.cpp | 2 ++
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/include/internal/catch_debugger.h b/include/internal/catch_debugger.h
index 6ca6a539..75419842 100644
--- a/include/internal/catch_debugger.h
+++ b/include/internal/catch_debugger.h
@@ -40,7 +40,10 @@ namespace Catch {
 #ifdef CATCH_TRAP
     #define CATCH_BREAK_INTO_DEBUGGER() if( Catch::isDebuggerActive() ) { CATCH_TRAP(); }
 #else
-    #define CATCH_BREAK_INTO_DEBUGGER() (void)0, 0
+    namespace Catch {
+        inline void doNothing() {}
+    }
+    #define CATCH_BREAK_INTO_DEBUGGER() Catch::doNothing()
 #endif
 
 #endif // TWOBLUECUBES_CATCH_DEBUGGER_H_INCLUDED
diff --git a/include/internal/catch_fatal_condition.cpp b/include/internal/catch_fatal_condition.cpp
index 0fa09f26..55ee539d 100644
--- a/include/internal/catch_fatal_condition.cpp
+++ b/include/internal/catch_fatal_condition.cpp
@@ -17,12 +17,14 @@
 #    pragma GCC diagnostic ignored "-Wmissing-field-initializers"
 #endif
 
+#if (defined(CATCH_PLATFORM_WINDOWS) && defined(CATCH_CONFIG_WINDOWS_SEH)) || defined(CATCH_CONFIG_POSIX_SIGNALS)
 namespace {
     // Report the error condition
     void reportFatal( char const * const message ) {
         Catch::getCurrentContext().getResultCapture()->handleFatalErrorCondition( message );
     }
 }
+#endif
 
 #if defined ( CATCH_PLATFORM_WINDOWS ) /////////////////////////////////////////