Skip to content

Commit 76c12cc

Browse files
author
Kyle Macomber
committed
Conform Never to Identifiable
Incorporating into `release/5.5` as part of evolution review discussion. This can be reverted if the Core team decides to not accept this change. rdar://75988520
1 parent 05f5405 commit 76c12cc

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

stdlib/public/core/Policy.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@ extension Never: Error {}
3434

3535
extension Never: Equatable, Comparable, Hashable {}
3636

37+
@available(macOS 12.0, iOS 15.0, watchOS 8.0, tvOS 15.0, *)
38+
extension Never: Identifiable {
39+
public var id: Never { fatalError() }
40+
}
41+
3742
//===----------------------------------------------------------------------===//
3843
// Standardized aliases
3944
//===----------------------------------------------------------------------===//

test/api-digester/stability-stdlib-abi-without-asserts.test

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,3 +57,4 @@ Protocol CodingKey has added inherited protocol Sendable
5757
Protocol CodingKey has generic signature change from <Self : Swift.CustomDebugStringConvertible, Self : Swift.CustomStringConvertible> to <Self : Swift.CustomDebugStringConvertible, Self : Swift.CustomStringConvertible, Self : Swift.Sendable>
5858
Protocol Error has added inherited protocol Sendable
5959
Protocol Error has generic signature change from to <Self : Swift.Sendable>
60+
Enum Never has added a conformance to an existing protocol Identifiable

0 commit comments

Comments
 (0)