Fast Mutable arrays and a general question about IO
Sun, 4 May 2003 05:10:06 +0100
Ron de Bruijn wrote:
> > import IOExts
> > data Lesson = Lesson String Int Int String String
> > deriving Show
> > main = do
> > test <- newIOArray (0,1) (Lesson "" 0 0 "" "")
> > ...
> IOExts is a Hugslibrary. Isn't it much slower than
> GHC's IOArray?
Both GHC and Hugs have IOExts, but only GHC has IOArray. GHC's IOExts
module imports IOArray then re-exports it, while Hugs' IOExts provides
IOArray directly. So, importing IOExts will work on both, and on GHC
provides the same IOArray type as when importing IOArray directly.
> P.S. It annoys me that GHC's library's are all
> compiled. Is there no way I can get there sources, so
> that they are portable between for instance Hugs or is
> placing the compiled files in your program folder
> enough to let Hugs understands the functions of GHC?
AFAIK, the only way to get the source for the GHC libraries is to
download the GHC source code. Some of those files will work with Hugs,
Glynn Clements <email@example.com>