MCPcopy Create free account
hub / github.com/Tencent/sluaunreal / luaT_init

Function luaT_init

Plugins/slua_unreal/External/lua/ltm.cpp:36–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34
35
36void luaT_init (lua_State *L) {
37 static const char *const luaT_eventname[] = { /* ORDER TM */
38 "__index", "__newindex",
39 "__gc", "__mode", "__len", "__eq",
40 "__add", "__sub", "__mul", "__mod", "__pow",
41 "__div", "__idiv",
42 "__band", "__bor", "__bxor", "__shl", "__shr",
43 "__unm", "__bnot", "__lt", "__le",
44 "__concat", "__call"
45 };
46 int i;
47 for (i=0; i<TM_N; i++) {
48 G(L)->tmname[i] = luaS_new(L, luaT_eventname[i]);
49 luaC_fix(L, obj2gco(G(L)->tmname[i])); /* never collect these names */
50 }
51}
52
53
54/*

Callers 1

f_luaopenFunction · 0.85

Calls 3

GFunction · 0.85
luaS_newFunction · 0.85
luaC_fixFunction · 0.85

Tested by

no test coverage detected