MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / get_compTM

Function get_compTM

Source/Misc/lua/src/lua.c:15005–15016  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15003
15004
15005static const TValue *get_compTM (lua_State *L, Table *mt1, Table *mt2,
15006TMS event) {
15007const TValue *tm1 = fasttm(L, mt1, event);
15008const TValue *tm2;
15009if (tm1 == NULL) return NULL; /* no metamethod */
15010if (mt1 == mt2) return tm1; /* same metatables => same metamethods */
15011tm2 = fasttm(L, mt2, event);
15012if (tm2 == NULL) return NULL; /* no metamethod */
15013if (luaO_rawequalObj(tm1, tm2)) /* same metamethods? */
15014return tm1;
15015return NULL;
15016}
15017
15018
15019static int call_orderTM (lua_State *L, const TValue *p1, const TValue *p2,

Callers 1

luaV_equalvalFunction · 0.85

Calls 1

luaO_rawequalObjFunction · 0.85

Tested by

no test coverage detected