Code review feedback from @jrose-apple for "95e9a0 The frontend should stop if the stdlib failed to load"

This commit is contained in:
Slava Pestov
2015-11-05 21:58:37 -08:00
parent 01c4c6a50d
commit cf3317ebf4
2 changed files with 5 additions and 2 deletions

View File

@@ -256,8 +256,11 @@ void CompilerInstance::performSema() {
}
// If we failed to load, we should have already diagnosed
if (M->failedToLoad())
if (M->failedToLoad()) {
assert(Diagnostics.hadAnyError() &&
"Module failed to load but nothing was diagnosed?");
return;
}
break;
}