Re: stdcall

Manuel M T Chakravarty <[email protected]>
Newsgroups gmane.comp.lang.haskell.ffi
Message-ID <[email protected]>
Ross Paterson <[email protected]> wrote,

> Could the meaning of stdcall be broadened to "the standard calling
> convention for libraries on the native system", i.e. pascal on Win32
> (as now) and ccall on Unix?  It would save a lot of fuss for interfaces
> to portable libraries.

If I am not mistaken, we have had this discussion before.
Unfortunately, haskell.org mailing list archives are not
easy to search, so please excuse the lack of reference.  In
fact, the FFI used to have a default calling convention and
we made a conscious decision against having a default.

"Simon Marlow" <[email protected]> wrote,

> So I'd say that specifying a "default" calling convention which maps to
> stdcall on Windows and ccall on Unix is probably a bad idea.  You've
> just got to know which one to use on Windows - this is the job for a
> tool which checks the FFI decls against the prototypes.

IIRC, that was the gist of the argument last time.  I
propose to stick with this previous decision.

Cheers,
Manuel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.