Creating stubs statically

Paolo Capriotti p.capriotti at
Thu Jul 5 14:13:50 CEST 2012

As explained in detail here:,
it may be useful to have a form of foreign declaration that creates a
static stub for a haskell function without exporting a symbol.

Here is a ticket for that:

It is not particularly clear how such a declaration would look like
syntactically. In the ticket I proposed the following:

    foreign import ccall myCallbackPtr :: FunPtr (IO ()) = myCallback

but please do suggest better alternatives.

It would also be useful to see some use cases of this new form of
declaration. Library binding authors: would this be a welcome addition
for you?


More information about the Glasgow-haskell-users mailing list