Alistair wrote
[snip]
> ps I still think we're better off removing header files completely and
> having the Haskell type completely determine the calling convention
> employed.  But since I'm not getting any takers on that, I'll settle for
> pinning down the spec as tightly as possible.
[snip]
Perhaps I'm missing something here, but in that case how on earth is the
poor user to find out if the Haskell type really corresponds to the C type,
before the program coredumps?

I see there is a problem here in that no such check can be carried out when
the compilation is not done via C.  Would it be possible for the compiler in such
a case to spit out a C file which typechecks if and only if the Haskell and C
prototypes match, and ask gcc to typecheck it?  You could even use this approach in
all cases, then C code compiled from Haskell would never need to include
user-supplied header files.
_______________________________________________
FFI mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/ffi

Reply via email to