lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

At 07:07 07/12/99 -0200, you wrote:
I'm trying to use loadlib under Windows. No problem on incorporating
the dll with "loadlib". "callfromlib" also works fine. But: How do I
have to declare and register a function within the DLL with Lua? As far
as I understand, I can't use "lua_register", as I can't simply pass the
function pointer across the DLL boundary.

Usually, We export from the DLL only one function, the one that registers all the functions in Lua. Very simple.

BTW, the functions you can call using loadlib are only "void func(void)" functions.