diff --git a/.github/workflows/ci_iwyu.yml b/.github/workflows/ci_iwyu.yml index 0cc086cf..4c7d4f31 100644 --- a/.github/workflows/ci_iwyu.yml +++ b/.github/workflows/ci_iwyu.yml @@ -44,7 +44,6 @@ jobs: - name: Install Dependencies run: | install libomp-17-dev libclang-17-dev - sudo ln -s /usr/lib/llvm-17/lib/clang/17 /usr/lib/llvm-17/lib/clang/17.0.0 - name: Install CMake uses: seqan/actions/setup-cmake@main @@ -56,7 +55,7 @@ jobs: clang-17 -print-resource-dir mkdir iwyu cd iwyu - git clone https://github.com/include-what-you-use/include-what-you-use.git + git clone https://github.com/include-what-you-use/include-what-you-use.git --branch 0.21 mkdir build cd build cmake ../include-what-you-use -G "Unix Makefiles" \ diff --git a/test/iwyu/mappings/gcc.symbols.imp b/test/iwyu/mappings/gcc.symbols.imp index 8b9e0fb8..7ac91fdc 100644 --- a/test/iwyu/mappings/gcc.symbols.imp +++ b/test/iwyu/mappings/gcc.symbols.imp @@ -18,56 +18,38 @@ [ { symbol: [ "aiocb", private, "", private ] }, { symbol: [ "blkcnt_t", private, "", private ] }, - { symbol: [ "blkcnt_t", private, "", private ] }, { symbol: [ "blksize_t", private, "", private ] }, - { symbol: [ "blksize_t", private, "", private ] }, { symbol: [ "cc_t", private, "", private ] }, - { symbol: [ "clock_t", private, "", private ] }, - { symbol: [ "clock_t", private, "", private ] }, { symbol: [ "clock_t", private, "", private ] }, + { symbol: [ "clock_t", private, "", private ] }, { symbol: [ "clockid_t", private, "", private ] }, - { symbol: [ "clockid_t", private, "", private ] }, { symbol: [ "daddr_t", private, "", private ] }, - { symbol: [ "daddr_t", private, "", private ] }, { symbol: [ "dev_t", private, "", private ] }, - { symbol: [ "dev_t", private, "", private ] }, { symbol: [ "div_t", private, "", private ] }, { symbol: [ "double_t", private, "", private ] }, { symbol: [ "error_t", private, "", private ] }, { symbol: [ "error_t", private, "", private ] }, { symbol: [ "error_t", private, "", private ] }, { symbol: [ "fd_set", private, "", private ] }, - { symbol: [ "fd_set", private, "", private ] }, { symbol: [ "fenv_t", private, "", private ] }, { symbol: [ "fexcept_t", private, "", private ] }, { symbol: [ "FILE", private, "", private ] }, { symbol: [ "FILE", private, "", private ] }, { symbol: [ "float_t", private, "", private ] }, { symbol: [ "fsblkcnt_t", private, "", private ] }, - { symbol: [ "fsblkcnt_t", private, "", private ] }, { symbol: [ "fsfilcnt_t", private, "", private ] }, - { symbol: [ "fsfilcnt_t", private, "", private ] }, { symbol: [ "getopt", private, "", private ] }, { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, - { symbol: [ "gid_t", private, "", private ] }, { symbol: [ "gid_t", private, "", private ] }, { symbol: [ "htonl", private, "", private ] }, { symbol: [ "htons", private, "", private ] }, { symbol: [ "id_t", private, "", private ] }, - { symbol: [ "id_t", private, "", private ] }, { symbol: [ "imaxdiv_t", private, "", private ] }, { symbol: [ "intmax_t", private, "", private ] }, { symbol: [ "uintmax_t", private, "", private ] }, { symbol: [ "ino64_t", private, "", private ] }, { symbol: [ "ino64_t", private, "", private ] }, { symbol: [ "ino_t", private, "", private ] }, - { symbol: [ "ino_t", private, "", private ] }, - { symbol: [ "ino_t", private, "", private ] }, { symbol: [ "int8_t", private, "", private ] }, { symbol: [ "int16_t", private, "", private ] }, { symbol: [ "int32_t", private, "", private ] }, @@ -79,155 +61,71 @@ { symbol: [ "intptr_t", private, "", private ] }, { symbol: [ "uintptr_t", private, "", private ] }, { symbol: [ "iovec", private, "", private ] }, - { symbol: [ "iovec", private, "", private ] }, { symbol: [ "itimerspec", private, "", private ] }, - { symbol: [ "itimerspec", private, "", private ] }, { symbol: [ "key_t", private, "", private ] }, - { symbol: [ "key_t", private, "", private ] }, { symbol: [ "lconv", private, "", private ] }, { symbol: [ "ldiv_t", private, "", private ] }, { symbol: [ "lldiv_t", private, "", private ] }, { symbol: [ "max_align_t", private, "", private ] }, { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, - { symbol: [ "mode_t", private, "", private ] }, { symbol: [ "nlink_t", private, "", private ] }, - { symbol: [ "nlink_t", private, "", private ] }, { symbol: [ "ntohl", private, "", private ] }, { symbol: [ "ntohs", private, "", private ] }, { symbol: [ "off64_t", private, "", private ] }, { symbol: [ "off64_t", private, "", private ] }, { symbol: [ "off_t", private, "", private ] }, - { symbol: [ "off_t", private, "", private ] }, - { symbol: [ "off_t", private, "", private ] }, - { symbol: [ "off_t", private, "", private ] }, - { symbol: [ "off_t", private, "", private ] }, - { symbol: [ "off_t", private, "", private ] }, { symbol: [ "off_t", private, "", private ] }, { symbol: [ "optarg", private, "", private ] }, { symbol: [ "opterr", private, "", private ] }, { symbol: [ "optind", private, "", private ] }, { symbol: [ "optopt", private, "", private ] }, { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, { symbol: [ "pid_t", private, "", private ] }, - { symbol: [ "pid_t", private, "", private ] }, { symbol: [ "ptrdiff_t", private, "", private ] }, { symbol: [ "regex_t", private, "", private ] }, { symbol: [ "regmatch_t", private, "", private ] }, { symbol: [ "regoff_t", private, "", private ] }, { symbol: [ "sigevent", private, "", private ] }, - { symbol: [ "sigevent", private, "", private ] }, - { symbol: [ "sigevent", private, "", private ] }, - { symbol: [ "sigevent", private, "", private ] }, { symbol: [ "siginfo_t", private, "", private ] }, - { symbol: [ "siginfo_t", private, "", private ] }, { symbol: [ "sigset_t", private, "", private ] }, - { symbol: [ "sigset_t", private, "", private ] }, - { symbol: [ "sigset_t", private, "", private ] }, { symbol: [ "sigval", private, "", private ] }, { symbol: [ "sockaddr", private, "", private ] }, { symbol: [ "socklen_t", private, "", private ] }, - { symbol: [ "socklen_t", private, "", private ] }, { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, - { symbol: [ "ssize_t", private, "", private ] }, { symbol: [ "ssize_t", private, "", private ] }, { symbol: [ "stat", private, "", private ] }, - { symbol: [ "stat", private, "", private ] }, { symbol: [ "suseconds_t", private, "", private ] }, - { symbol: [ "suseconds_t", private, "", private ] }, - { symbol: [ "suseconds_t", private, "", private ] }, { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, { symbol: [ "time_t", private, "", private ] }, - { symbol: [ "time_t", private, "", private ] }, { symbol: [ "timer_t", private, "", private ] }, - { symbol: [ "timer_t", private, "", private ] }, { symbol: [ "timespec", private, "", private ] }, - { symbol: [ "timespec", private, "", private ] }, - { symbol: [ "timespec", private, "", private ] }, - { symbol: [ "timespec", private, "", private ] }, { symbol: [ "timespec", private, "", private ] }, - { symbol: [ "timespec", private, "", private ] }, - { symbol: [ "timespec", private, "", private ] }, { symbol: [ "timeval", private, "", private ] }, - { symbol: [ "timeval", private, "", private ] }, - { symbol: [ "timeval", private, "", private ] }, - { symbol: [ "timeval", private, "", private ] }, { symbol: [ "tm", private, "", private ] }, { symbol: [ "u_char", private, "", private ] }, - { symbol: [ "u_char", private, "", private ] }, { symbol: [ "uid_t", private, "", private ] }, - { symbol: [ "uid_t", private, "", private ] }, - { symbol: [ "uid_t", private, "", private ] }, - { symbol: [ "uid_t", private, "", private ] }, - { symbol: [ "uid_t", private, "", private ] }, - { symbol: [ "uid_t", private, "", private ] }, { symbol: [ "uid_t", private, "", private ] }, { symbol: [ "useconds_t", private, "", private ] }, { symbol: [ "useconds_t", private, "", private ] }, { symbol: [ "wchar_t", private, "", private ] }, { symbol: [ "wchar_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, { symbol: [ "size_t", private, "", private ] }, - { symbol: [ "size_t", private, "", private ] }, # Macros that can be defined in more than one file, don't have the # same __foo_defined guard that other types do, so the grep above # doesn't discover them. Until I figure out a better way, I just # add them in by hand as I discover them. { symbol: [ "EOF", private, "", private ] }, - { symbol: [ "EOF", private, "", private ] }, { symbol: [ "FILE", private, "", private ] }, + { symbol: [ "IBSHIFT", private, "", private ] }, { symbol: [ "MAP_POPULATE", private, "", private ] }, { symbol: [ "MAP_POPULATE", private, "", private ] }, { symbol: [ "MAP_STACK", private, "", private ] }, @@ -236,7 +134,6 @@ { symbol: [ "MAXHOSTNAMELEN", private, "", private ] }, { symbol: [ "SIGABRT", private, "", private ] }, { symbol: [ "SIGCHLD", private, "", private ] }, - { symbol: [ "SIGCHLD", private, "", private ] }, { symbol: [ "va_list", private, "", private ] }, { symbol: [ "va_list", private, "", private ] }, { symbol: [ "va_list", private, "", private ] }, @@ -262,6 +159,7 @@ { symbol: [ "NULL", private, "", private ] }, { symbol: [ "NULL", private, "", private ] }, { symbol: [ "NULL", private, "", private ] }, + { symbol: [ "offsetof", private, "", private ] }, # GCC defines std::declval in , but the canonical location is { symbol: [ "std::declval", private, "", public ] },