I am trying to use SWIG to generate Ruby wrapper for a
projet using SWIG.

In out project, there are a lot of functions which
take a function object parameter (Apply<T>)
and call then may call the call method of this
object. I would like to wrap it with a Ruby code
which takes a block and the creates a new apply
object whose call function calls the block.
Is it possible to solve this problem with
SWIG typemaps? I have read the whole documentation,
but I did not see any way to solve this.

In our case, we can assume that the
Apply parameter occures only once in the
parameter list as the last parameter.

Basically, I would need a typemap which tells
that the C++ arugment should not map to any
Ruby argument, but should take its parameter
somewhere else. (Like multivariable typemaps,
which map more parameters to one, here I would
like to map one parameter to no parameter at all.

Does someone have an idea to solve this problem?

Thanks, Christian