3 ms·
PUC Lua is supposedly a bit of a pain for ffi, but I havent tried it myself. Luajit is some kind of crazy magic. You can (almost) just copy and paste the c head
by PinkMilkshake 1y ago
PUC Lua is supposedly a bit of a pain for ffi, but I havent tried it myself. Luajit is some kind of crazy magic. You can (almost) just copy and paste the c header file into the ffi.cdef function and then start using c functions as if they were lua functions.
- gucci-on-fleek 1y agoThe LuaJIT ffi module has been ported to PUC Lua [0] (and abandoned and forked dozens of times), and it works pretty well in my experience. [0]: https://github.com/dibyendumajumdar/ravi-ffi https://github.com/dibyendumajumdar/ravi-ffi