[AST/Sema] Add a diagnostic group ExplicitSendable to replace -require-explicit-sendable

Always run explicit `Sendable` checks on public types and suppress
warning printing by default instead of using a special compiler argument.

Resolves: rdar://162394810
This commit is contained in:
Pavel Yaskevich
2025-11-04 12:17:15 -08:00
parent 5eb4ab260c
commit 22ec081377
6 changed files with 40 additions and 8 deletions

View File

@@ -2857,9 +2857,9 @@ WARNING(remove_public_import,none,
WARNING(remove_package_import,none,
"package import of %0 was not used in package declarations",
(Identifier))
WARNING(public_decl_needs_sendable,none,
"public %kind0 does not specify whether it is 'Sendable' or not",
(const ValueDecl *))
GROUPED_WARNING(public_decl_needs_sendable,ExplicitSendable,none,
"public %kind0 does not specify whether it is 'Sendable' or not",
(const ValueDecl *))
NOTE(explicit_disable_sendable,none,
"make %kind0 explicitly non-Sendable to suppress this warning",
(const ValueDecl *))