GHCI/FFI/GMP/Me madness

Remi Turk buran at xs4all.nl
Mon Aug 9 13:36:37 EDT 2004


On Mon, Aug 09, 2004 at 01:09:40PM -0400, Abraham Egnor wrote:
> FWIW, I couldn't reproduce this problem on my system (i.e. str_test
> always printed "1").  GHC 6.2.1, libgmp 4.1.3, debian unstable
> 
> Abe

Same versions here, on an old heavily-patched/FUBAR rock linux
1.4 system.

Does the following make any difference? (trying to cause GCing)

Haskell/Mpz/weird% make
ghci util.o -#include util.h PrimMpz.hs
   ___         ___ _
  / _ \ /\  /\/ __(_)
 / /_\// /_/ / /  | |      GHC Interactive, version 6.2.1, for Haskell 98.
/ /_\\/ __  / /___| |      http://www.haskell.org/ghc/
\____/\/ /_/\____/|_|      Type :? for help.

Loading package base ... linking ... done.
Loading object (static) util.o ... done
final link ... done
Compiling Main             ( PrimMpz.hs, interpreted )
Ok, modules loaded: Main.
*Main> mpz_new
*Main> sum (replicate (200*1000) 0)
0
*Main> str_test
1076535944
*Main> 


Groeten,
Remi

-- 
Nobody can be exactly like me. Even I have trouble doing it.


More information about the Glasgow-haskell-users mailing list