[preamble] Also record the "skipping" state of the preprocessor
authorErik Verbruggen <erikjv@me.com>
Fri, 3 Nov 2017 09:40:07 +0000 (09:40 +0000)
committerErik Verbruggen <erikjv@me.com>
Fri, 3 Nov 2017 09:40:07 +0000 (09:40 +0000)
commit4d1eb2d5cb97b99fc0d8559661a7b569dc8ecc90
tree41228f5cc84ebac7b103b02ef68f181967647fae
parent8c825db25e32365652c9d68177224f8c3c1a551a
[preamble] Also record the "skipping" state of the preprocessor

When a preamble ends in a conditional preprocessor block that is being
skipped, the preprocessor needs to continue skipping that block when
the preamble is used.

This fixes PR34570.

llvm-svn: 317308
clang/include/clang/Lex/Preprocessor.h
clang/lib/Lex/PPDirectives.cpp
clang/lib/Lex/Preprocessor.cpp
clang/lib/Serialization/ASTReader.cpp
clang/lib/Serialization/ASTWriter.cpp
clang/test/Index/preamble-conditionals-inverted.cpp
clang/test/Index/preamble-conditionals-skipping.cpp [new file with mode: 0644]