Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorPhil Nash2016-05-12 19:17:55 +0100
committerPhil Nash2016-05-12 19:17:55 +0100
commit7940d58a2fee08156fa310356534f1a1290408df (patch)
tree5fb7d6a93b6c98654685997da656dc8b9ddc3ef1 /include
parentebf9f3bb9db48148b3ee6a3b066a770e148f5ce7 (diff)
downloadcatch3-7940d58a2fee08156fa310356534f1a1290408df.tar.gz
"test" expression using !! instead of static_cast to bool.
This addresses #657 while (hopefully) maintaining fix for #574
Diffstat (limited to 'include')
-rw-r--r--include/internal/catch_capture.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/internal/catch_capture.hpp b/include/internal/catch_capture.hpp
index 1496fe3a..fa5835b8 100644
--- a/include/internal/catch_capture.hpp
+++ b/include/internal/catch_capture.hpp
@@ -40,7 +40,7 @@
__catchResult.useActiveException( Catch::ResultDisposition::Normal ); \
} \
INTERNAL_CATCH_REACT( __catchResult ) \
- } while( Catch::isTrue( false && static_cast<bool>(expr) ) ) // expr here is never evaluated at runtime but it forces the compiler to give it a look
+ } while( Catch::isTrue( false && !!(expr) ) ) // expr here is never evaluated at runtime but it forces the compiler to give it a look
///////////////////////////////////////////////////////////////////////////////
#define INTERNAL_CATCH_IF( expr, resultDisposition, macroName ) \