Commit Graph

4 Commits

Author SHA1 Message Date
Slava Pestov
c4e804a7d1 AST: Fix TypeBase::hasSimpleTypeRepr() for ProtocolCompositionType
Prior to the introduction of noncopyable generics, a ProtocolCompositionType
was 'simple' if it was exactly 'Any' or 'AnyObject'. Now, there is a new
simple case, where we have a single inverse requirement '~Copyable' or
'~Escapable', and the old logic was never updated to account for this
possibility. Instead, it would ignore inverses, so it would claim that
a composition like `P & ~Copyable` was simple when it shouldn't be.

Fixes rdar://139465298.
2025-02-26 16:56:27 -05:00
Holly Borla
e9c14cd88b [ASTPrinter] Print the desugared constraint type following the 'any'
keyword.
2022-05-23 19:43:51 -07:00
Allan Shortlidge
60146b32b4 Sema: Accept existentials without any in swiftinterfaces.
Resolves rdar://93052306
2022-05-10 17:43:05 -07:00
Allan Shortlidge
e0e748c35a ModuleInterface: Print existential any in swiftinterfaces since any is required for protocols with associated types in 5.7.
Resolves rdar://92976269
2022-05-09 14:10:07 -07:00