http://en.wikipedia.org/wiki/Trampoline_(computing)
http://gcc.gnu.org/onlinedocs/gcc/Nested-Functions.html
FFcall can be used to do simillar things: http://www.gnu.org/software/libffcall/
It has four subprojects:
* avcall - build a C argument list incrementally and call a C function on it.
* vacall - C functions called with variable arguments
* trampoline - closures as first-class C functions
* callback - closures with variable arguments as first-class C functions
[update] used outdated link to http://www.haible.de/bruno/packages-ffcall.html
http://en.wikipedia.org/wiki/Trampoline_(computing)
http://gcc.gnu.org/onlinedocs/gcc/Nested-Functions.html
FFcall can be used to do simillar things: http://www.gnu.org/software/libffcall/
It has four subprojects:
* avcall - build a C argument list incrementally and call a C function on it.
* vacall - C functions called with variable arguments
* trampoline - closures as first-class C functions
* callback - closures with variable arguments as first-class C functions
[update] used outdated link to http://www.haible.de/bruno/packages-ffcall.html