[Haskell-cafe] pure programs

Alberto G. Corona agocorona at gmail.com
Wed Nov 5 03:52:54 EST 2008


A performance improvement could be the caching of responses based on
computation costs and number of accesses. This functionality can be
implemented a general module that may be used to wrap any pure program if
needed. This is something that only pure programs can ever do. And the
haskell type system can enforce that.

2008/11/5 Bulat Ziganshin <bulat.ziganshin at gmail.com>

> Hello Jason,
>
> Wednesday, November 5, 2008, 3:12:29 AM, you wrote:
>
> >   Many useful programs that I would like to write in Haskell
> >   don't fall into this category -- for example, network servers
> >   -- but a lot of their components do. Can these components can
> >   be Haskell functions without IO in their signatures?
>
> pure function is one those result depends only on its arguments. as
> far as you can provide "input stream" as an function argument, it
> should be possible to write it in pure way (as far as you don't
> concern efficiency. sometimes imperative algorithms mauy be just
> faster than pure ones since data structures are different)
>
>
> --
> Best regards,
>  Bulat                            mailto:Bulat.Ziganshin at gmail.com
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20081105/64c91cd0/attachment.htm


More information about the Haskell-Cafe mailing list