Show last breath error
Even when exceptions are not available exception object is still alive, so we may extract the message
This commit is contained in:
parent
647711fad1
commit
2f5ec0b848
@ -95,7 +95,7 @@ SOFTWARE.
|
|||||||
#define JSON_TRY try
|
#define JSON_TRY try
|
||||||
#define JSON_CATCH(exception) catch(exception)
|
#define JSON_CATCH(exception) catch(exception)
|
||||||
#else
|
#else
|
||||||
#define JSON_THROW(exception) std::abort()
|
#define JSON_THROW(exception) std::cerr<<exception.what()<<std::endl; std::abort()
|
||||||
#define JSON_TRY if(true)
|
#define JSON_TRY if(true)
|
||||||
#define JSON_CATCH(exception) if(false)
|
#define JSON_CATCH(exception) if(false)
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user