AST: Record -sil-serialize-all in the ModuleDecl

We want to distinguish the special case of a library built with
-sil-serialize-all, from a SIL function that is [fragile] because
of an explicitly @_transparent or @inline(__always).

For now, NFC.
This commit is contained in:
Slava Pestov
2016-03-28 00:23:56 -07:00
parent 5f8426b206
commit 1ce1e78951
11 changed files with 86 additions and 36 deletions

View File

@@ -170,14 +170,14 @@ FileUnit *SerializedModuleLoader::loadAST(
if (err == serialization::Status::Valid) {
Ctx.bumpGeneration();
M.setResilienceStrategy(extendedInfo.getResilienceStrategy());
// We've loaded the file. Now try to bring it into the AST.
auto fileUnit = new (Ctx) SerializedASTFile(M, *loadedModuleFile,
extendedInfo.isSIB());
M.addFile(*fileUnit);
if (extendedInfo.isTestable())
M.setTestingEnabled();
if (extendedInfo.isResilient())
M.setResilienceEnabled();
auto diagLocOrInvalid = diagLoc.getValueOr(SourceLoc());
err = loadedModuleFile->associateWithFileContext(fileUnit,