mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Invoke TryAddFinal after type checking.
Run whole-module checks at the end of perform Sema, specifically TryAddFinal. After everything has been type checked, accessibility has been provided, and we have had a chance to see any potential overrides, we try to add the final attribute to class members. This ends up de-virtualizing many functions, or rather they avoid the vtable altogether. Thus, there are many test file changes. New test file add_final.swift. Other tests updated to either reflect the non-virtual call, or to have public added to them. Swift SVN r20338
This commit is contained in:
@@ -437,6 +437,8 @@ void CompilerInstance::performSema() {
|
||||
performDelayedParsing(MainModule, PersistentState,
|
||||
Invocation.getCodeCompletionFactory());
|
||||
}
|
||||
|
||||
performWholeModuleChecks(MainModule, PrimaryBufferID == NO_SUCH_BUFFER);
|
||||
}
|
||||
|
||||
void CompilerInstance::performParseOnly() {
|
||||
|
||||
Reference in New Issue
Block a user