shared: move _noreturn definition into helpers.h

This commit is contained in:
Sam James 2023-01-25 04:00:01 +00:00 committed by Mike Frysinger
parent a6568c304f
commit ddf4a3a7a0
2 changed files with 2 additions and 8 deletions

View File

@ -18,14 +18,6 @@
#include "_usage.h" #include "_usage.h"
#include "version.h" #include "version.h"
#if lint
# define _noreturn
#endif
#if __GNUC__ > 2 || defined(__INTEL_COMPILER)
# define _noreturn __attribute__ ((__noreturn__))
#else
# define _noreturn
#endif
void set_quiet_options(void) void set_quiet_options(void)
{ {

View File

@ -27,10 +27,12 @@
#endif #endif
#if __GNUC__ > 2 || defined(__INTEL_COMPILER) #if __GNUC__ > 2 || defined(__INTEL_COMPILER)
# define _dead __attribute__((__noreturn__)) # define _dead __attribute__((__noreturn__))
# define _noreturn __attribute__ ((__noreturn__))
# define _unused __attribute__((__unused__)) # define _unused __attribute__((__unused__))
# define _xasprintf(a, b) __attribute__((__format__(__printf__, a, b))) # define _xasprintf(a, b) __attribute__((__format__(__printf__, a, b)))
#else #else
# define _dead # define _dead
# define _noreturn
# define _unused # define _unused
# define _xasprintf(a, b) # define _xasprintf(a, b)
#endif #endif