mirror of
https://github.com/apple/swift-async-algorithms
synced 2026-11-24 04:17:52 +00:00
* [AsyncStreaming] Propagate cancellation to late readers Distinguish cancellation from normal source completion when a reader continuation is installed after the channel has already finished. * [AsyncStreaming] Distinguish terminal read states Track cancellation separately from an already-consumed terminal result so normal source completion does not throw CancellationError. Precondition on repeated reads after cancellation, a final element, or a source failure, with coverage for each terminal path. * [AsyncStreaming] Handle pending reader cancellation Deliver cancellation exactly once when it races with a resumed reader, preserve fused final-element completion, and align terminal-read tests and documentation with the reader contract. * [AsyncStreaming] Test cancellation through public API Remove the internal-only state-machine test so the regression suite exercises the supported AsyncStreaming interface without @testable import.