Unverified Commit a3efd892 authored by Jan Svoboda's avatar Jan Svoboda Committed by GitHub
Browse files

[clang][modules] Don't prevent translation of FW_Private includes when...

[clang][modules] Don't prevent translation of FW_Private includes when explicitly building FW (#70714)

We prevent translating `#include <FW/PrivateHeader.h>` into an import of
FW_Private when compiling the implementation of FW or FW_Private. This
is specified via `-fmodule-name=` on the TU command line (used to be
`-fmodule-implementation-of`).

This logic is supposed to only kick in when imported directly from a TU,
but it currently also kicks in when compiling the public FW module
explicitly (since it also has `-fmodule-name=` on the command line).

This patch makes sure this logic only kicks in for the case that used to
be `-fmodule-implementation-of` (for the TU), and not for all
`-fmodule-name=` cases (especially for the explicit compile of a
module).

rdar://101051277; related: rdar://37500098&38434694
parent 243588df
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment