mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[AST] NFC: Formalize Decl validation tracking via RAII
After this change, RAII ensures that the validation state is accurate as possible.
This commit is contained in:
@@ -1521,7 +1521,7 @@ void TypeChecker::completePropertyBehaviorParameter(VarDecl *VD,
|
||||
|
||||
Parameter->setInterfaceType(SubstInterfaceTy);
|
||||
Parameter->setGenericEnvironment(genericEnv);
|
||||
Parameter->setValidationStarted();
|
||||
Parameter->setValidationToChecked();
|
||||
|
||||
// Mark the method to be final, implicit, and private. In a class, this
|
||||
// prevents it from being dynamically dispatched.
|
||||
@@ -2510,7 +2510,7 @@ swift::createDesignatedInitOverride(TypeChecker &tc,
|
||||
ctor->setGenericEnvironment(genericEnv);
|
||||
|
||||
tc.configureInterfaceType(ctor, genericSig);
|
||||
ctor->setValidationStarted();
|
||||
ctor->setValidationToChecked();
|
||||
|
||||
configureDesignatedInitAttributes(tc, classDecl,
|
||||
ctor, superclassCtor);
|
||||
|
||||
Reference in New Issue
Block a user