> Going via C is fine, as long as you -#include the relevant prototype for the
> C function you're calling. Otherwise the C compiler automatically promotes
> the arguments/result to doubles and you're hosed.
>
> There's been a great deal of discussion on the FFI list (as I'm sure you've
> seen) about how to do this properly. We can't just generate a prototype
> inline
Ah, yes, I'd completely forgotten about that issue. But how do I
#include a C header into a Haskell source file? (Doubtless there
is a ghc extension to help.) And, even easier, can I #include the
actual C source directly?
Regards,
Malcolm