Commit Graph

10 Commits

Author SHA1 Message Date
Doug Gregor
f21c60928c Add feature for rethrows protocols and use it in module interface generation 2021-02-22 16:18:47 -08:00
Doug Gregor
2fd1912f5a Simplify printing of marker protocols in Swift interfaces
Thanks to a great idea from Slava, simplify the printing of marker
protocols in Swift interfaces while maintaining backward compatibility.
For compilers that cannot handle marker protocols, print a typealias
to `Any` instead, which is a good stand-in for just about everything.
2021-02-18 22:58:19 -08:00
Doug Gregor
e8375e13ee Define a feature for @concurrent functions. 2021-02-12 16:36:12 -08:00
Doug Gregor
43df1d8363 [Concurrency] Don't spuriously record protocols inherited by Actor. 2021-02-10 15:52:03 -08:00
swift-ci
bcfafc1b07 Merge pull request #35854 from davezarzycki/pr35854 2021-02-09 13:07:51 -08:00
David Zarzycki
5a17429b25 [Testing] Add missing REQUIRES: concurrency 2021-02-09 13:26:44 -05:00
Doug Gregor
b1aa56dbd1 Clean up test comment and mark as REQUIRES: concurrency 2021-02-09 09:28:17 -08:00
Doug Gregor
643ce71a09 Peer into the types of declarations to find async/actors/etc. 2021-02-08 22:50:48 -08:00
Doug Gregor
627e4f03a3 Properly print protocols that inherit marker protocols under $MarkerProtocol 2021-02-08 22:37:13 -08:00
Doug Gregor
aa139a101c [Module interface] Use features in module interface generation.
When generating a module interface, emit `#if` around any declarations
that are tied to specific, named language features. This allows module
interfaces to be processed by older Swift compilers that do not
support these newer features, such as async/await or actors.

The amount of effort required to correctly handle a new kind of
feature varies somewhat drastically based on the feature itself. The
"simple" case is where a particular declaration can only exist if a
feature is available. For example, and `async` declaration is fairly
easy to handle; a `@_marker` protocol's conformances are not.

Fixes rdar://73326633.
2021-02-08 16:01:39 -08:00