don't use Clang modules in the "only re-export public symbols" check (#66610)

rdar://110399757
This commit is contained in:
QuietMisdreavus
2023-06-15 10:13:18 -06:00
committed by GitHub
parent e69c3015f7
commit 85d59d2e55
4 changed files with 48 additions and 10 deletions

View File

@@ -718,7 +718,10 @@ bool SymbolGraph::isImplicitlyPrivate(const Decl *D,
// Symbols from exported-imported modules should only be included if they
// were originally public.
if (Walker.isFromExportedImportedModule(D) &&
// We force compiler-equality here to ensure that the presence of an underlying
// Clang module does not prevent internal Swift symbols from being emitted when
// MinimumAccessLevel is set to `internal` or below.
if (Walker.isFromExportedImportedModule(D, /*countUnderlyingClangModule*/false) &&
VD->getFormalAccess() < AccessLevel::Public) {
return true;
}