
3 May
2017
3 May
'17
9:20 p.m.
On 03/05/2017, Olaf Klinke
Streams can be given a Traversable instance easily:
instance Traversable Stream where sequenceA (Cons fa fas) = liftA2 Cons fa (sequenceA fas)
For some applicatives this will not terminate. For streams of Maybes, sequenceA will either yield Just an infinite stream or return Nothing.
I believe this will never return `Just` an infinite stream — rather, it will not terminate.