MCPcopy Create free account
hub / github.com/Tencent/xLua / xlua_push_csharp_function

Function xlua_push_csharp_function

WebGLPlugins/xlua.c:753–764  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

751}
752
753LUA_API void xlua_push_csharp_function(lua_State* L, lua_CFunction fn, int n)
754{
755 lua_pushcfunction(L, fn);
756 if (n > 0) {
757 lua_insert(L, -1 - n);
758 }
759 lua_pushboolean(L, 0);
760 if (n > 0) {
761 lua_insert(L, -1 - n);
762 }
763 lua_pushcclosure(L, csharp_function_wrap, 2 + (n > 0 ? n : 0));
764}
765
766typedef int (*lua_CSWrapperCaller) (lua_State *L, int wrapperid, int top);
767

Callers 1

Calls 3

lua_insertFunction · 0.85
lua_pushbooleanFunction · 0.85
lua_pushcclosureFunction · 0.85

Tested by

no test coverage detected