Skip to content

Commit 8fe48b6

Browse files
authored
Constrain AsyncThrowingStream.init(unfolding:) where Failure == Error
1 parent 1a29c96 commit 8fe48b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

stdlib/public/Concurrency/AsyncThrowingStream.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ public struct AsyncThrowingStream<Element, Failure: Error> {
138138

139139
public init(
140140
unfolding produce: @escaping () async throws -> Element?
141-
) {
141+
) where Failure == Error {
142142
self.produce = produce
143143
}
144144
}

0 commit comments

Comments
 (0)