[Haskell-cafe] Library function for map+append

Bayley, Alistair Alistair.Bayley at invesco.com
Tue Aug 18 07:03:12 EDT 2009


> From: haskell-cafe-bounces at haskell.org 
> [mailto:haskell-cafe-bounces at haskell.org] On Behalf Of Dusan Kolar
> 
>   During a small project I'm trying to develop a small 
> application. It 
> becomes quite often that I need a function mapapp:
> 
> mapapp _ [] ap = ap
> mapapp f (a:as) ap = f a : map f as ap
> 
>   I tried hoogle to find such a function with no success. Is 
> there any 
> function/functions built-in "standard" libraries that could easily 
> satisfy the functionality with the same or even better (?) efficiency?


What does mapapp do? What is its type?

At first I thought maybe you were rewriting concatMap, but now I can't
tell what you're doing.
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data-List.htm
l#v%3AconcatMap

Alistair
*****************************************************************
Confidentiality Note: The information contained in this message,
and any attachments, may contain confidential and/or privileged
material. It is intended solely for the person(s) or entity to
which it is addressed. Any review, retransmission, dissemination,
or taking of any action in reliance upon this information by
persons or entities other than the intended recipient(s) is
prohibited. If you received this in error, please contact the
sender and delete the material from any computer.
*****************************************************************



More information about the Haskell-Cafe mailing list