diff options
author | Jack Lloyd <[email protected]> | 2016-09-26 20:41:11 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2016-09-26 20:41:11 -0400 |
commit | 16131507a198c1b0ac608e4313bf02d41ab2f3b5 (patch) | |
tree | 7fc013750400911bdb6ec754afa6885ab8f6b404 /src/lib/utils/assert.h | |
parent | 7df9d0dcd968a4c0462b6e95dae4ec847b04199e (diff) | |
parent | 507d926da825fbc1d9d74b4517dbab47702c66b9 (diff) |
Merge GH #516 Cipher_Mode API improvements
Diffstat (limited to 'src/lib/utils/assert.h')
-rw-r--r-- | src/lib/utils/assert.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/lib/utils/assert.h b/src/lib/utils/assert.h index f80f9b170..c49ae62ee 100644 --- a/src/lib/utils/assert.h +++ b/src/lib/utils/assert.h @@ -35,6 +35,19 @@ BOTAN_NORETURN void BOTAN_DLL assertion_failure(const char* expr_str, } while(0) /** +* Make an assertion +*/ +#define BOTAN_ASSERT_NOMSG(expr) \ + do { \ + if(!(expr)) \ + Botan::assertion_failure(#expr, \ + "", \ + BOTAN_CURRENT_FUNCTION, \ + __FILE__, \ + __LINE__); \ + } while(0) + +/** * Assert that value1 == value2 */ #define BOTAN_ASSERT_EQUAL(expr1, expr2, assertion_made) \ |