HOpenGL did it once again... :-} The NCG for x86
doesn't honour the calling convention for "wrappers":
-- example module ------------------------------------
module CB where
import Foreign.C.Types ( CInt )
import Foreign.Ptr ( FunPtr )
type Callback = CInt -> IO ()
foreign import ccall "wrapper" makeCallback1 ::
Callback -> IO (FunPtr Callback)
foreign import stdcall "wrapper" makeCallback2 ::
Callback -> IO (FunPtr Callback)
-- shell transcript ----------------------------------
$ rm -f *.o ; ghc -c -fffi CB.hs ; nm *.o|grep _CB_d
U _CB_dS1
U _CB_dS2 <= !!!!!!!!!! @8 is missing
00000008 T _CB_dS1
00000070 T _CB_dS2@8
$ rm -f *.o ; ghc -c -fffi CB.hs -O ; nm *.o|grep
_CB_d
U _CB_dUu@8
U _CB_dUv
00000070 T _CB_dUu@8
------------------------------------------------------
I'd be grateful if this would be be fixed for the next
patchlevel release.
Cheers,
S.
__________________________________________________________________
Gesendet von Yahoo! Mail - http://mail.yahoo.de
M�chten Sie mit einem Gru� antworten? http://grusskarten.yahoo.de
_______________________________________________
Cvs-ghc mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/cvs-ghc