3 ms·
luv is a lua bindung for the libuv library which means that it uses all the C API provided by the lua language to code the interface between C functions and lua
by benjaminva 12y ago
luv is a lua bindung for the libuv library which means that it uses all the C API provided by the lua language to code the interface between C functions and lua functions.
Here we have a FFI-binding which means that only the header of the C functions are sufficient for the ffi library to handle all conversions of variables to and from the lua environment. Additional interface related functions are coded in lua instead of C.
Luajit provides a powerful FFI implementation which makes it very easy to provide interfaces to C libraries. However, it is not part of the vanilla lua implementation which is why both versions have their reasons to exist.