diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2019-05-09 09:06:26 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2019-05-09 09:09:35 -0700 |
commit | 8570cb9b74426d849ed78f57b6e78a0d043b9330 (patch) | |
tree | b01a12fd1e5af279055b68a2fcecd42d180fc22d /lib/verify.h | |
parent | 89a5b4b828b962361be83904b5914ec4bb3408ec (diff) | |
download | gnulib-8570cb9b74426d849ed78f57b6e78a0d043b9330.tar.gz |
verify: remove verify_true
* NEWS: Mention this.
* lib/verify.h (verify_true): Remove.
* tests/test-verify.c (item): Test verify_expr, not verify_true.
Diffstat (limited to 'lib/verify.h')
-rw-r--r-- | lib/verify.h | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/lib/verify.h b/lib/verify.h index d7e15bc8a3..f8e4eff026 100644 --- a/lib/verify.h +++ b/lib/verify.h @@ -149,9 +149,9 @@ which do not support _Static_assert, also do not warn about the last declaration mentioned above. - * GCC warns if -Wnested-externs is enabled and verify() is used + * GCC warns if -Wnested-externs is enabled and 'verify' is used within a function body; but inside a function, you can always - arrange to use verify_expr() instead. + arrange to use verify_expr instead. * In C++, any struct definition inside sizeof is invalid. Use a template type to work around the problem. */ @@ -235,17 +235,10 @@ template <int w> assert (R), there is no run-time overhead. There are two macros, since no single macro can be used in all - contexts in C. verify_true (R) is for scalar contexts, including + contexts in C. verify_expr (R, E) is for scalar contexts, including integer constant expression contexts. verify (R) is for declaration contexts, e.g., the top level. */ -/* Verify requirement R at compile-time, as an integer constant expression. - Return 1. This is equivalent to verify_expr (R, 1). - - verify_true is obsolescent; please use verify_expr instead. */ - -#define verify_true(R) _GL_VERIFY_TRUE (R) - /* Verify requirement R at compile-time. Return the value of the expression E. */ |