Commit Graph

3 Commits

Author SHA1 Message Date
Doug Gregor
8ff7e0b3ab Look to enclosing declarations for @available attributes on @_nonSendable types
`@_nonSendable` types get a synthesized, unavailable extension that
declares the Sendable conformance. This extension also needs to have
appropriate platform availability for the type that is being marked
non-Sendable, so the platform-specific attributes are copied from the
nominal type declaration. However, for nested types, we might need to
copy those attributes from an enclosing declarations. Do so when
appropriate.

Fixes rdar://90330588.
2022-07-06 22:16:16 -07:00
Allan Shortlidge
747f286b8d ModuleInterface: Adopt new swiftinterface verification lit substitutions pervasively in tests where they can be adopted by simply updating or adding a few RUN: lines. 2022-04-15 20:13:00 -07:00
Doug Gregor
5e50ee8560 Add @available attributes on the implicit "extension" for @_nonSendable types
`@_nonSendable` on a type effectively desugars to an unavailable
extension that provides (`@unchecked`) conformance to the `Sendable`
protocol. Make sure we copy over platform availability so that the
extension does not promise greater availability than the type it extends.

Fixes rdar://90330588.
2022-03-25 11:01:44 -07:00