mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Delay the validaton of storage accessors until finalization.
The base mutability of storage is part of the signature, so be sure to compute that during validation. Also, serialize it as part of the storage declaration, and fix some places that synthesize declarations to set it correctly.
This commit is contained in:
@@ -2894,6 +2894,8 @@ void Serializer::writeDecl(const Decl *D) {
|
||||
var->isStatic(),
|
||||
getRawStableVarDeclSpecifier(var->getSpecifier()),
|
||||
var->hasNonPatternBindingInit(),
|
||||
var->isGetterMutating(),
|
||||
var->isSetterMutating(),
|
||||
(unsigned) accessors.Kind,
|
||||
addTypeRef(ty),
|
||||
addDeclRef(accessors.Get),
|
||||
@@ -3047,6 +3049,8 @@ void Serializer::writeDecl(const Decl *D) {
|
||||
contextID,
|
||||
subscript->isImplicit(),
|
||||
subscript->isObjC(),
|
||||
subscript->isGetterMutating(),
|
||||
subscript->isSetterMutating(),
|
||||
(unsigned) accessors.Kind,
|
||||
addGenericEnvironmentRef(
|
||||
subscript->getGenericEnvironment()),
|
||||
|
||||
Reference in New Issue
Block a user