I have C++ application which uses Lua C API. I declared global table via lua api:
lua_newtable(L);
lua_pushstring(L, "someLuaFunc");
lua_pushcfunction(L, &someCFunc);
lua_settable(L, -3);
lua_setglobal(L, "table1");
and now I can call someLuaFunc using '.' or ':'
table1.someLuaFunc()
table1:someLuaFunc()
and both cases will run someCFunc.
Question is: is there any way, inside someCFunc, to determine how it was called (via : or .)?
Checking argument count and types is not an option in my case.