4 ms·
If you call 'next' on an IO stream, you always get the same answer, an IO effect which, when executed, would destructively get the next item: next :: Stream
by Peaker 10y ago
If you call 'next' on an IO stream, you always get the same answer, an IO effect which, when executed, would destructively get the next item:
next :: Stream a -> IO a
The function part is pure. The `execution` of the resulting `IO a` action (which is completely separate from its pure evaluation) is not.