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
Change CATCH_BREAK_INTO_DEBUGGER to always expand into a function call
- Commit
75200b462c51fe1af163b0727325af3367d1fe21- Author
- Martin Hořeňovský ·
- Parents
17e09be3b928
Changes
include/internal/catch_debugger.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/include/internal/catch_debugger.h b/include/internal/catch_debugger.h index 75419842..db3ff681 100644 --- a/include/internal/catch_debugger.h +++ b/include/internal/catch_debugger.h @@ -38,12 +38,9 @@ namespace Catch { #endif #ifdef CATCH_TRAP - #define CATCH_BREAK_INTO_DEBUGGER() if( Catch::isDebuggerActive() ) { CATCH_TRAP(); } + #define CATCH_BREAK_INTO_DEBUGGER() []{ if( Catch::isDebuggerActive() ) { CATCH_TRAP(); } }() #else - namespace Catch { - inline void doNothing() {} - } - #define CATCH_BREAK_INTO_DEBUGGER() Catch::doNothing() + #define CATCH_BREAK_INTO_DEBUGGER() []{}() #endif #endif // TWOBLUECUBES_CATCH_DEBUGGER_H_INCLUDED