[Haskell-cafe] Re: Wikipedia on first-class object

Achim Schneider barsoap at web.de
Sun Dec 30 13:51:41 EST 2007


"Cristian Baboi" <cristian.baboi at gmail.com> wrote:

> module Module where
> 
> a= let x=1:x in x
> 
> main = <do something to write a (a notation for a) to file>
> 
> The function must work if one change a to let x=2:x in x, let
> x=1:2:3:x and variations on the same theme.

import GHC?
you can even load it directly to memory and execute it via
unsafeCoerce# (which is the most evil function haskell has to offer).

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 



More information about the Haskell-Cafe mailing list