[Haskell-cafe] Beginner: IORef constructor?
tjay.dreaming at gmail.com
Fri Dec 1 02:08:09 EST 2006
First of all, sorry if this is a really silly question, but I couldn't
figure it out from experimenting in GHCi and from the GHC libraries
documentation (or Google).
Is there an IORef consturctor? Or is it just internal to the Data.IORef module?
I want a "global variable", so I did the following:
module VirtualWorld where
theWorld = IORef  -- This will be writeIORef'ed with a populated
list as the user modifies the world.
It doesn't work. GHCi says that the IORef constructor is not in scope.
I did a ":module Data.IORef" and then "IORef " and it still gives me
the same error.
I'm using GHC 6.6 on Windows.
More information about the Haskell-Cafe