diff options
Diffstat (limited to 'ltm.c')
-rw-r--r-- | ltm.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -188,6 +188,15 @@ void luaT_trybiniTM (lua_State *L, const TValue *p1, lua_Integer i2, | |||
188 | } | 188 | } |
189 | 189 | ||
190 | 190 | ||
191 | /* | ||
192 | ** Calls an order tag method. | ||
193 | ** For lessequal, LUA_COMPAT_LT_LE keeps compatibility with old | ||
194 | ** behavior: if there is no '__le', try '__lt', based on l <= r iff | ||
195 | ** !(r < l) (assuming a total order). If the metamethod yields during | ||
196 | ** this substitution, the continuation has to know about it (to negate | ||
197 | ** the result of r<l); bit CIST_LEQ in the call status keeps that | ||
198 | ** information. | ||
199 | */ | ||
191 | int luaT_callorderTM (lua_State *L, const TValue *p1, const TValue *p2, | 200 | int luaT_callorderTM (lua_State *L, const TValue *p1, const TValue *p2, |
192 | TMS event) { | 201 | TMS event) { |
193 | if (callbinTM(L, p1, p2, L->top, event)) /* try original event */ | 202 | if (callbinTM(L, p1, p2, L->top, event)) /* try original event */ |