[SourceKit] Make sure to propagate the SIL options from the compiler invocation when doing performSILGeneration() to get the SIL diagnostics

rdar://32329669
This commit is contained in:
Argyrios Kyrtzidis
2017-05-22 18:27:41 -07:00
parent d1bd12f7cb
commit 323c07e562
2 changed files with 16 additions and 1 deletions

View File

@@ -835,7 +835,7 @@ ASTUnitRef ASTProducer::createASTUnit(SwiftASTManager::Implementation &MgrImpl,
// don't block any other AST processing for the same SwiftInvocation.
if (auto SF = CompIns.getPrimarySourceFile()) {
SILOptions SILOpts;
SILOptions SILOpts = Invocation.getSILOptions();
std::unique_ptr<SILModule> SILMod = performSILGeneration(*SF, SILOpts);
runSILDiagnosticPasses(*SILMod);
}