From ce616246fc28183a9fd134db94f5f12db8e394de Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 16 Aug 2020 19:09:00 +0200 Subject: [PATCH] argp: Emit a warning also with clang. * lib/argp-help.c (__argp_short_program_name): Use #warning also on clang. --- ChangeLog | 6 ++++++ lib/argp-help.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index a56da8343b..7a6c05695b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2020-08-16 Bruno Haible + + argp: Emit a warning also with clang. + * lib/argp-help.c (__argp_short_program_name): Use #warning also on + clang. + 2020-08-16 Bruno Haible libc-config: Enable __REDIRECT macro also on clang. diff --git a/lib/argp-help.c b/lib/argp-help.c index 73987ba66e..52260f35e8 100644 --- a/lib/argp-help.c +++ b/lib/argp-help.c @@ -1723,7 +1723,7 @@ __argp_short_program_name (void) /* FIXME: What now? Miles suggests that it is better to use NULL, but currently the value is passed on directly to fputs_unlocked, so that requires more changes. */ -# if __GNUC__ +# if __GNUC__ || (__clang_major__ >= 4) # warning No reasonable value to return # endif /* __GNUC__ */ return ""; -- 2.39.5