Add condition resolution as a new phrase post-parse

An unfortunately necessary thing to delay defrosting function bodies as
long as we can.
This commit is contained in:
Robert Widmann
2016-12-03 20:47:18 -05:00
parent 72beb9d80d
commit cededef0d6
17 changed files with 683 additions and 335 deletions

View File

@@ -446,6 +446,7 @@ void CompilerInstance::performSema() {
Diags.setSuppressWarnings(DidSuppressWarnings);
performConditionResolution(*NextInput);
performNameBinding(*NextInput);
}
@@ -508,8 +509,10 @@ void CompilerInstance::performSema() {
if (mainIsPrimary && !Context->hadError() &&
Invocation.getFrontendOptions().PlaygroundTransform)
performPlaygroundTransform(MainFile, Invocation.getFrontendOptions().PlaygroundHighPerformance);
if (!mainIsPrimary)
if (!mainIsPrimary) {
performConditionResolution(MainFile);
performNameBinding(MainFile);
}
}
// Type-check each top-level input besides the main source file.