mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[SourceKit/DocInfo] Add is_async for properties with async getters
Resolves rdar://80546521
This commit is contained in:
@@ -428,6 +428,9 @@ static bool initDocEntityInfo(const Decl *D,
|
||||
Info.IsOptional = D->getAttrs().hasAttribute<OptionalAttr>();
|
||||
if (auto *AFD = dyn_cast<AbstractFunctionDecl>(D)) {
|
||||
Info.IsAsync = AFD->hasAsync();
|
||||
} else if (auto *Storage = dyn_cast<AbstractStorageDecl>(D)) {
|
||||
if (auto *Getter = Storage->getAccessor(AccessorKind::Get))
|
||||
Info.IsAsync = Getter->hasAsync();
|
||||
}
|
||||
|
||||
if (!IsRef) {
|
||||
|
||||
Reference in New Issue
Block a user