Hacker News new | ask | show | jobs
by justincormack 5591 days ago
The LuaJit FFI includes a C parser so you can pretty much just paste in the header file. http://luajit.org/ext_ffi_tutorial.html - its not complete yet but seems pretty nice. You could do something like that for Ruby. For Lua it is also much faster than using the standard C bindings as the optimizer can see what is going on.

Having an FFI like this in a language is a really nice feature.