Skip to content

Commit 4c169c1

Browse files
author
Kyle Macomber
committed
Conform Never to Identifiable
rdar://75988520
1 parent 4e4752a commit 4c169c1

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
@@ -70,5 +70,6 @@ Protocol CodingKey has added inherited protocol Sendable
7070
Protocol CodingKey has generic signature change from <Self : Swift.CustomDebugStringConvertible, Self : Swift.CustomStringConvertible> to <Self : Swift.CustomDebugStringConvertible, Self : Swift.CustomStringConvertible, Self : Swift.Sendable>
7171
Protocol Error has added inherited protocol Sendable
7272
Protocol Error has generic signature change from to <Self : Swift.Sendable>
73+
Enum Never has added a conformance to an existing protocol Identifiable
7374

7475
// *** DO NOT DISABLE OR XFAIL THIS TEST. *** (See comment above.)

0 commit comments

Comments
 (0)