]> Savannah Git Hosting - gnulib.git/commit
include_next: pacify clang -Winclude-next-absolute-path
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 28 Dec 2023 20:25:16 +0000 (12:25 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 28 Dec 2023 20:29:08 +0000 (12:29 -0800)
commitf4fccf8efdd09d5e38f49f6ae1962797ce3e8e9c
treea5b2a708077a1f3d2b8f864de6f9cbaa91115318
parent00cf42bb77bb69f680f38e278155a425875cf37b
include_next: pacify clang -Winclude-next-absolute-path

Without this change, Ubuntu clang version 16.0.6 (15) issues
warnings like this: “In file included from xalloc-die.c:25:
./error.h:28:3: warning: #include_next in file found relative to
primary source file or found by absolute path; will search from
start of include path [-Winclude-next-absolute-path]”.
And sure enough, each file includes itself rather than the
next include file and it’s only the subsidiary include that
gets around to including the next include file.
* lib/argmatch.c, lib/chdir-long.c, lib/clean-temp-simple.c:
* lib/clean-temp.c, lib/closein.c, lib/closeout.c, lib/copy-acl.c:
* lib/copy-file.c, lib/creat.c, lib/csharpcomp.c:
* lib/csharpexec.c, lib/error.c, lib/exclude.c, lib/execute.c:
* lib/faccessat.c, lib/fopen.c, lib/freopen.c, lib/getopt.c:
* lib/getopt1.c, lib/git-merge-changelog.c, lib/javacomp.c:
* lib/javaexec.c, lib/javaversion.c, lib/mkdir-p.c, lib/open.c:
* lib/openat-die.c, lib/openat.c, lib/os2-spawn.c:
* lib/pagealign_alloc.c, lib/pipe-filter-gi.c:
* lib/pipe-filter-ii.c, lib/same.c, lib/set-acl.c:
* lib/sigpipe-die.c, lib/spawn-pipe.c, lib/sys_socket.c, lib/truncate.c:
* lib/unistd.c, lib/verror.c, lib/wait-process.c, lib/wctype-h.c:
* lib/xalloc-die.c, lib/xfreopen.c, lib/xmemcoll.c, lib/xprintf.c:
* lib/xsetenv.c, lib/xstdopen.c, lib/xstrtol-error.c:
Use ‘#include <foo.h>’ instead of ‘#include "foo.h"’ if foo.h
possibly uses #include_next.  (However, don’t do this on OSF/1
which has its own problems.)
49 files changed:
ChangeLog
lib/argmatch.c
lib/chdir-long.c
lib/clean-temp-simple.c
lib/clean-temp.c
lib/closein.c
lib/closeout.c
lib/copy-acl.c
lib/copy-file.c
lib/creat.c
lib/csharpcomp.c
lib/csharpexec.c
lib/error.c
lib/exclude.c
lib/execute.c
lib/faccessat.c
lib/fopen.c
lib/freopen.c
lib/getopt.c
lib/getopt1.c
lib/git-merge-changelog.c
lib/javacomp.c
lib/javaexec.c
lib/javaversion.c
lib/mkdir-p.c
lib/open.c
lib/openat-die.c
lib/openat.c
lib/os2-spawn.c
lib/pagealign_alloc.c
lib/pipe-filter-gi.c
lib/pipe-filter-ii.c
lib/same.c
lib/set-acl.c
lib/sigpipe-die.c
lib/spawn-pipe.c
lib/sys_socket.c
lib/truncate.c
lib/unistd.c
lib/verror.c
lib/wait-process.c
lib/wctype-h.c
lib/xalloc-die.c
lib/xfreopen.c
lib/xmemcoll.c
lib/xprintf.c
lib/xsetenv.c
lib/xstdopen.c
lib/xstrtol-error.c