[Haskell] Re: ANNOUNCE: HNOP 0.1

Bjorn Bringert bringert at cs.chalmers.se
Sat Jul 1 04:24:44 EDT 2006


On Jun 30, 2006, at 1:01 AM, Ashley Yakeley wrote:

> In article
> <252C89C12FCAD84BA018CAD5268682FD0190C955 at GBLONXMB02.corp.amvescap.net 
> >,
>  "Bayley, Alistair" <Alistair_Bayley at invescoperpetual.co.uk> wrote:
>
>> Cool, that's awesome. But I don't see any Haddock docs? Or a Cabal
>> Setup.hs? Would it be much trouble to add them?
>
> Bear in mind HNOP compiles just to an executable file, so it doesn't
> really have a Haskell API.
>
> One interesting line of development would be to spin off the core
> functionality into a separate library, to provide no-op services to
> other Haskell applications. I'm thinking something like this:
>
>   noop :: IO ()  -- generalise to other Monads?
>
> This would actually not be too hard to write, given my existing work,
> and then of course the executable would simply be a thin wrapper.

As suggested above, this patch moves the core functionality to a  
library module, Control.Nop. Furthermore, the nop function is  
generalized to a polyvariadic function, so that you can now write for  
example:

import Control.Nop

main :: IO ()
main = nop "Hello World!"

and still get the expected lack of results.

/Björn

-------------- next part --------------
A non-text attachment was scrubbed...
Name: control-nop.patch
Type: application/octet-stream
Size: 1957 bytes
Desc: not available
Url : http://www.haskell.org//pipermail/haskell/attachments/20060701/df31989d/control-nop.obj
-------------- next part --------------



More information about the Haskell mailing list