AST: Introduce Decl::isUnavailable().

Replace calls to `AvailableAttr::isUnavailable()` with `Decl::isUnavailable()`.
This commit is contained in:
Allan Shortlidge
2024-11-23 17:39:07 -08:00
parent 94f4b0598a
commit 1dc7aa5b7b
19 changed files with 41 additions and 26 deletions

View File

@@ -335,7 +335,7 @@ bool ProtocolConformanceRef::hasUnavailableConformance() const {
auto concrete = getConcrete();
auto *dc = concrete->getRootConformance()->getDeclContext();
auto ext = dyn_cast<ExtensionDecl>(dc);
if (ext && AvailableAttr::isUnavailable(ext))
if (ext && ext->isUnavailable())
return true;
// Check the conformances in the substitution map.