mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Since values of generic type are currently assumed to always support copying, we need to prevent move-only types from being substituted for generic type parameters. This approach leans on a `_Copyable` marker protocol to which all generic type parameters implicitly must conform. A few other changes in this initial implementation: - Now every concrete type that can conform to Copyable will do so. This fixes issues with conforming to a protocol that requires Copyable. - Narrowly ban writing a concrete type `[T]` when `T` is move-only.
565 KiB
565 KiB