@@ -1268,6 +1268,13 @@ static const char *getImportFailureString(swift::serialization::Status status) {
1268
1268
case swift::serialization::Status::TargetTooNew:
1269
1269
return " The module file was built for a target newer than the current "
1270
1270
" target." ;
1271
+ case swift::serialization::Status::RevisionIncompatible:
1272
+ return " The module file was built for a different version of the compiler." ;
1273
+ case swift::serialization::Status::NotInOSSA:
1274
+ return " The module file was not compiled with -enable-ossa-modules when it "
1275
+ " was required to do so." ;
1276
+ case swift::serialization::Status::SDKMismatch:
1277
+ return " The module file was built with a different SDK version." ;
1271
1278
}
1272
1279
}
1273
1280
@@ -1355,7 +1362,7 @@ static bool DeserializeAllCompilerFlags(swift::CompilerInvocation &invocation,
1355
1362
for (; !buf.empty (); buf = buf.substr (info.bytes )) {
1356
1363
swift::serialization::ExtendedValidationInfo extended_validation_info;
1357
1364
info = swift::serialization::validateSerializedAST (
1358
- buf, &extended_validation_info);
1365
+ buf, /* requiresOSSAModules= */ false , &extended_validation_info);
1359
1366
bool invalid_ast = info.status != swift::serialization::Status::Valid;
1360
1367
bool invalid_size = (info.bytes == 0 ) || (info.bytes > buf.size ());
1361
1368
bool invalid_name = info.name .empty ();
@@ -3347,9 +3354,9 @@ swift::ASTContext *SwiftASTContext::GetASTContext() {
3347
3354
3348
3355
LLDB_SCOPED_TIMER ();
3349
3356
m_ast_context_ap.reset (swift::ASTContext::get (
3350
- GetLanguageOptions (), GetTypeCheckerOptions (), GetSearchPathOptions (),
3351
- GetClangImporterOptions (), GetSymbolGraphOptions (),
3352
- GetSourceManager (), GetDiagnosticEngine ()));
3357
+ GetLanguageOptions (), GetTypeCheckerOptions (), GetSILOptions (),
3358
+ GetSearchPathOptions (), GetClangImporterOptions (),
3359
+ GetSymbolGraphOptions (), GetSourceManager (), GetDiagnosticEngine ()));
3353
3360
m_diagnostic_consumer_ap.reset (new StoringDiagnosticConsumer (*this ));
3354
3361
3355
3362
if (getenv (" LLDB_SWIFT_DUMP_DIAGS" )) {
0 commit comments