[cffi-devel] defcallback with &rest

Luís Oliveira luismbo at gmail.com
Fri Dec 2 18:46:41 UTC 2011


On Fri, Dec 2, 2011 at 5:36 PM, Frank Goenninger <frgo at me.com> wrote:
> (defun frgo (fmt &rest args)
>  (format t fmt args))
>
> Now I want to define a C call back for that function:
>
> (defcallback frgoc :void ((fmt :string) (args ???????
>
> How do I define the callback such that I can have a C function with varargs being defined?

Sorry, no way to do that right now. Last time I checked, no Lisp's got
support for such a feature. We might start using libffi to add extra
(low-level) features in the near feature, but not even libffi supports
this particular feature.

-- 
Luís Oliveira
http://r42.eu/~luis/




More information about the cffi-devel mailing list