You need to use H/Direct 0.17, which unfortunately you have to compile
from source. 0.16 (which I presume you're using) doesn't work with GHC
4.08.2.
I checked your example against the CVS HEAD version of H/Direct, and it
worked fine, except that I had to make the following changes (to correct
unintentional errors, I presume):
[incr.c]
+ #include <windows.h>
- BOOL WINAPI DllMain(args...) { return TRUE; }
+ BOOL WINAPI DllMain(args) { return TRUE; }
int __declspec(dllexport) incr(int x) { return x + 1; }
[incr.idl]
module Incr { [pure]int incr([in]int); }
[Main.hs]
module Main(main) where
+ import Incr
main = print (incr 2)
_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users