[Haskell-cafe] Safe/Unsafe calls with the GHC Foreign Function Interface

Rob Hoelz hoelz at wisc.edu
Thu May 17 23:32:11 EDT 2007


More questions from Rob regarding his mysterious bindings...

So I've been reading the docs for the FFI, and it's my understanding
that foreign functions imported as "unsafe" are faster, but they've got
a problem with callbacks.  From what I read, I believe that I should
just make a foreign function safe if it sets up a callback; is this
correct?  Normally I wouldn't bother people with questions like this,
but I'd rather be absolutely certain and avoid tracking down a strange
bug later.

Many thanks as always,
Rob


More information about the Haskell-Cafe mailing list