[AST/Sema] Allow Sendable suppression on Objective-C class declarations

Expressed as `__swift_attr__("~Sendable")` this acts like `: ~Sendable`
on Swift type declarations and supersedes `@_nonSendable(_assumed)`.

Resolves: rdar://140928937
This commit is contained in:
Pavel Yaskevich
2025-10-24 15:24:19 +09:00
parent 2c1329e861
commit 65599ce1f1
6 changed files with 83 additions and 6 deletions

View File

@@ -1248,6 +1248,8 @@ void NominalTypeDecl::prepareConformanceTable() const {
// Add protocols for any synthesized protocol attributes.
for (auto attr : getAttrs().getAttributes<SynthesizedProtocolAttr>()) {
if (attr->isSuppressed())
continue;
addSynthesized(attr->getProtocol());
}