Can/Should AsyncStream have runtime checks for multiple subscribers?

In my opinion, this has become more relevant now and is worth further exploring. With the introduction of the share operator in AsyncAlgorithms, where one extra or less line of code can make a huge difference, perhaps we could generalize this 'warning' for AsyncSequence as a whole?

P.S. A somewhat related and interesting post about the difference between AsyncStream and AsyncThrowingStream: 'Consuming an AsyncStream from multiple Tasks' Redux

1 Like