[Yaroslav Kavenchuk wonders about ffi:c-function and (ffi:c-ptr ffi:c-function...)]
Excellent question indeed.
CLISP impnotes' example section covers an example similar to yours. Of course, examples are only informative, not normative, but I don't think right now that more text should be added to impnotes on this topic, do you?
Basically, for arguments, you use (c-function ...) as meaning "pointer to function", since that's all that C passes on the stack.
For creating function objects using the with-c-var trick I showed you, you can consider c-function as meaning "the function object".
Therefore, (c-ptr (c-function #)) is usually wrong.
>What example corresponds to c-definition:
>int f2( int *f1(int x), int y);
(f1 (c-function (:arguments (x int))
-- Just like in the impnotes examples.