mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
AST: Introduce Decl::getDeprecatedAttr().
It replaces `DeclAttr::getDeprecated()` as the designated way to query for the attribute that makes a decl deprecated.
This commit is contained in:
@@ -444,7 +444,7 @@ static bool initDocEntityInfo(const Decl *D,
|
||||
}
|
||||
|
||||
Info.IsUnavailable = D->isUnavailable();
|
||||
Info.IsDeprecated = D->getAttrs().isDeprecated(D->getASTContext());
|
||||
Info.IsDeprecated = D->isDeprecated();
|
||||
Info.IsOptional = D->getAttrs().hasAttribute<OptionalAttr>();
|
||||
if (auto *AFD = dyn_cast<AbstractFunctionDecl>(D)) {
|
||||
Info.IsAsync = AFD->hasAsync();
|
||||
|
||||
Reference in New Issue
Block a user