Mercurial > hg > octave-jordi > gnulib-hg
changeset 15399:75580bffd82c
c-stack: use _Noreturn
* lib/c-stack.c (die, overflow_handler, segv_handler):
Use _Noreturn rather than __attribute__((noreturn)).
author | Paul Eggert <eggert@cs.ucla.edu> |
---|---|
date | Tue, 12 Jul 2011 01:06:07 -0700 |
parents | 7a89429c129d |
children | 786020647d93 |
files | ChangeLog lib/c-stack.c |
diffstat | 2 files changed, 7 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2011-07-12 Paul Eggert <eggert@cs.ucla.edu> + c-stack: use _Noreturn + * lib/c-stack.c (die, overflow_handler, segv_handler): + Use _Noreturn rather than __attribute__((noreturn)). + argmatch-tests, exclude_tests: use _Noreturn * tests/test-argmatch.c, tests/test-exclude.c (_GL_ATTRIBUTE_NORETURN): Remove.
--- a/lib/c-stack.c +++ b/lib/c-stack.c @@ -104,8 +104,7 @@ appears to have been a stack overflow, or with a core dump otherwise. This function is async-signal-safe. */ -static void die (int) __attribute__ ((noreturn)); -static void +static _Noreturn void die (int signo) { char const *message; @@ -182,9 +181,7 @@ /* Handle a segmentation violation that is likely to be a stack overflow and exit. This function is async-signal-safe. */ -static void overflow_handler (int, stackoverflow_context_t) - __attribute__ ((noreturn)); -static void +static _Noreturn void overflow_handler (int emergency, stackoverflow_context_t context __attribute__ ((unused))) { @@ -228,8 +225,7 @@ /* Handle a segmentation violation and exit. This function is async-signal-safe. */ -static void segv_handler (int, siginfo_t *, void *) __attribute__((noreturn)); -static void +static _Noreturn void segv_handler (int signo, siginfo_t *info, void *context __attribute__ ((unused))) {