Skip to content
Commit 17da34d2 authored by Bruno Cardoso Lopes's avatar Bruno Cardoso Lopes
Browse files

[PCH] Fix a regression when PCH is used with -fmodules

Following up on r291465 after a regression in r276159. When we use
-fmodule-name=X while building a PCH, modular headers in X will be
textually included and the compiler knows that we are not building
module X, so don't serialize such headers in the PCH as being part of a
module, because at this point they are not.

This was causing subtle bugs and malformed AST crashes, for instance,
when using the PCH in subsequent compiler invocation with -fmodules, the
HFI for a modular header would map to the PCH, which would force a
module load of and unexistent module ID.

rdar://problem/30171164

llvm-svn: 294361
parent c0d5590a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment