
6 Dec
2007
6 Dec
'07
8:25 p.m.
On Thu, Dec 06, 2007 at 11:40:58PM +0100, Ben Franksen wrote:
Aaron Denney wrote:
On 2007-12-06, Wolfgang Jeltsch
wrote: list comprehensions deal with specific operations (map, filter, etc.) of a specific type ([]).
Ah, so we should bring back monad comprehensions?
I don't miss monad comprehension much, but I'd like to have a way to use comprehension for other sequence types, notably ByteString, array types and Data.Sequence (other than converting to lists and back).
If we had monad comprehensions and some kind of restricted monads (see my post 'Constructor classes considered harmful', but note that I didn't then and still don't have a tolerable replacement), we'd get bytestring / sequence comprehensions for free. Stefan