diff options
Diffstat (limited to 'libctf/ctf-inlines.h')
-rw-r--r-- | libctf/ctf-inlines.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libctf/ctf-inlines.h b/libctf/ctf-inlines.h index a35b6cd..affc9f9 100644 --- a/libctf/ctf-inlines.h +++ b/libctf/ctf-inlines.h @@ -80,6 +80,16 @@ ctf_dynset_cinsert (ctf_dynset_t *h, const void *k) return ctf_dynset_insert (h, (void *) k); } +static inline int +ctf_assert_internal (ctf_file_t *fp, const char *file, size_t line, + const char *exprstr, int expr) +{ + if (_libctf_unlikely_ (!expr)) + ctf_assert_fail_internal (fp, file, line, exprstr); + + return expr; +} + #ifdef __cplusplus } #endif |