Bug in touchForeignPtr?

Abraham Egnor abe.egnor at gmail.com
Mon Nov 22 12:48:26 EST 2004

> If finalizers are not the right thing, what else is?

I've found that when writing an interface to a C library that requires
resource management, it's much better to use the withX (see
Control.Exception.bracket) style of function than to use finalizers -
programs are much easier to reason about and debug.


More information about the Glasgow-haskell-users mailing list