[clang] [clang][ExtractAPI] Stop dropping fields of nested anonymous record types when they aren't attached to variable declaration (PR #104600)

LLVM Continuous Integration via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 19 08:00:49 PDT 2024


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `clang-armv8-quick` running on `linaro-clang-armv8-quick` while building `clang` at step 4 "build stage 1".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/154/builds/2973

Here is the relevant piece of the build log for the reference:
```
Step 4 (build stage 1) failure: 'ninja' (failure)
...
[63/145] Linking CXX executable bin/amdgpu-arch
[64/145] Linking CXX executable bin/clang-offload-bundler
[65/145] Linking CXX executable bin/llvm-link
[66/145] Linking CXX executable bin/nvptx-arch
[67/145] Generating ../../bin/llvm-otool
[68/145] Linking CXX executable bin/llvm-profgen
[69/145] Linking CXX executable bin/clang-pseudo-fuzzer
[70/145] Linking CXX executable bin/clang-pseudo
[71/145] Linking CXX executable bin/llvm-jitlink
[72/145] Building CXX object tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXExtractAPI.cpp.o
FAILED: tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXExtractAPI.cpp.o 
/usr/local/bin/c++ -DGTEST_HAS_RTTI=0 -D_CINDEX_LIB_ -D_DEBUG -D_FILE_OFFSET_BITS=64 -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/tcwg-buildbot/worker/clang-armv8-quick/stage1/tools/clang/tools/libclang -I/home/tcwg-buildbot/worker/clang-armv8-quick/llvm/clang/tools/libclang -I/home/tcwg-buildbot/worker/clang-armv8-quick/llvm/clang/include -I/home/tcwg-buildbot/worker/clang-armv8-quick/stage1/tools/clang/include -I/home/tcwg-buildbot/worker/clang-armv8-quick/stage1/include -I/home/tcwg-buildbot/worker/clang-armv8-quick/llvm/llvm/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -fno-common -Woverloaded-virtual -Wno-nested-anon-types -O3 -DNDEBUG -std=c++17 -fPIC  -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -MD -MT tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXExtractAPI.cpp.o -MF tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXExtractAPI.cpp.o.d -o tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXExtractAPI.cpp.o -c /home/tcwg-buildbot/worker/clang-armv8-quick/llvm/clang/tools/libclang/CXExtractAPI.cpp
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:164:38: error: member access into incomplete type 'SourceManager'
  164 |     return Context.getSourceManager().isInSystemHeader(D->getLocation());
      |                                      ^
../llvm/clang/include/clang/Basic/SourceLocation.h:34:7: note: forward declaration of 'clang::SourceManager'
   34 | class SourceManager;
      |       ^
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:293:33: error: member access into incomplete type 'SourceManager'
  293 |       Context.getSourceManager().getPresumedLoc(Decl->getLocation());
      |                                 ^
../llvm/clang/include/clang/Basic/SourceLocation.h:34:7: note: forward declaration of 'clang::SourceManager'
   34 | class SourceManager;
      |       ^
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:366:33: error: member access into incomplete type 'SourceManager'
  366 |       Context.getSourceManager().getPresumedLoc(Decl->getLocation());
      |                                 ^
../llvm/clang/include/clang/Basic/SourceLocation.h:34:7: note: forward declaration of 'clang::SourceManager'
   34 | class SourceManager;
      |       ^
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:404:33: error: member access into incomplete type 'SourceManager'
  404 |       Context.getSourceManager().getPresumedLoc(Decl->getLocation());
      |                                 ^
../llvm/clang/include/clang/Basic/SourceLocation.h:34:7: note: forward declaration of 'clang::SourceManager'
   34 | class SourceManager;
      |       ^
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:535:33: error: member access into incomplete type 'SourceManager'
  535 |       Context.getSourceManager().getPresumedLoc(Decl->getLocation());
      |                                 ^
../llvm/clang/include/clang/Basic/SourceLocation.h:34:7: note: forward declaration of 'clang::SourceManager'
   34 | class SourceManager;
      |       ^
In file included from ../llvm/clang/tools/libclang/CXExtractAPI.cpp:25:
../llvm/clang/include/clang/ExtractAPI/ExtractAPIVisitor.h:581:33: error: member access into incomplete type 'SourceManager'

```

https://github.com/llvm/llvm-project/pull/104600


More information about the cfe-commits mailing list