[PATCH] D14329: Show inclusions from a preamble in clang_getInclusions.

Erik Verbruggen via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 4 04:30:21 PST 2015


erikjv created this revision.
erikjv added a reviewer: klimek.
erikjv added a subscriber: cfe-commits.

When reparsing a translation unit with preamble generation turned on,
no includes are found. This is due to the fact that all SLocs from
AST/PCH files are skipped as they are 'loaded', and inclusions from a
preamble are also 'loaded'. So, in case a file has a preamble, it first
needs to process those loaded inclusions, and then check for any local
inclusions. This latter one is for any includes that are not part of the
preamble, like includes half-way through a file.

http://reviews.llvm.org/D14329

Files:
  test/Index/cindex-test-inclusions.c
  tools/c-index-test/c-index-test.c
  tools/libclang/CIndexInclusionStack.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14329.39187.patch
Type: text/x-patch
Size: 6246 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20151104/165d6cf7/attachment.bin>


More information about the cfe-commits mailing list