[Cffi-devel] cffi idioms: with-foreign-pointer
Mirko Vukovic
mirko.vukovic at gmail.com
Sun Feb 8 00:55:48 UTC 2015
Does with-foreign-pointer free up the memory after body is executed?
I have been using constructs such as:
(let ((num-channel-groups* (foreign-alloc :uint)))
(ddc-get-num-channel-groups file-handle* num-channel-groups*)
(prog1 (mem-ref num-channel-groups* :uint)
(foreign-free num-channel-groups*)))
Is with-foreign-pointer the idiomatic way to accomplish the same thing?
Thanks
Mirko
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cffi-devel/attachments/20150207/8f6000a3/attachment.html>
More information about the cffi-devel
mailing list