diff options
Diffstat (limited to 'src/inc')
-rw-r--r-- | src/inc/debugreturn.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/inc/debugreturn.h b/src/inc/debugreturn.h index 74567534b1..a2dae5d61e 100644 --- a/src/inc/debugreturn.h +++ b/src/inc/debugreturn.h @@ -93,7 +93,11 @@ typedef __SafeToReturn __ReturnOK; // The call is dead, and does not appear in the generated code, even in a checked // build. (And, in fastchecked, there is no penalty at all.) // +#ifdef _MSC_VER +#define return if (0 && __ReturnOK::safe_to_return()) { } else return +#else // _MSC_VER #define return for (;1;__ReturnOK::safe_to_return()) return +#endif // _MSC_VER #define DEBUG_ASSURE_NO_RETURN_BEGIN(arg) { typedef __YouCannotUseAReturnStatementHere __ReturnOK; if (0 && __ReturnOK::used()) { } else { #define DEBUG_ASSURE_NO_RETURN_END(arg) } } |