Add @_private(from: "SourceFile.swift") imports

A module compiled with `-enable-private-imports` allows other modules to
import private declarations if the importing source file uses an
``@_private(from: "SourceFile.swift") import statement.

rdar://29318654
This commit is contained in:
Arnold Schwaighofer
2018-11-08 07:57:22 -08:00
parent a952514c5f
commit 963c64e3e7
33 changed files with 605 additions and 47 deletions

View File

@@ -113,6 +113,9 @@ static bool readOptionsBlock(llvm::BitstreamCursor &cursor,
case options_block::IS_TESTABLE:
extendedInfo.setIsTestable(true);
break;
case options_block::ARE_PRIVATE_IMPORTS_ENABLED:
extendedInfo.setPrivateImportsEnabled(true);
break;
case options_block::RESILIENCE_STRATEGY:
unsigned Strategy;
options_block::ResilienceStrategyLayout::readRecord(scratch, Strategy);