lua-users home
lua-l archive

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

Hi All
I just came across a page, which is very close to what I am looking.

The above link gives an idea how to have a generic C function to call any Lua function.

Anybody used this concept? Please let me know.

Best Regards

On Tue, Jul 8, 2014 at 11:50 AM, steve donovan <> wrote:
On Mon, Jul 7, 2014 at 10:07 PM, Tom N Harris <> wrote:
> To support calling an arbitrary function, you need to include information
> about the types of the arguments in addition to the name.
> And use it like:
>     execute_lua_function(L, "lua_f3", "iis", 5, 10, "foo");

This is exactly the approach taken by llua: