** return 'l < r' for non-numbers. */
| 521 | ** return 'l < r' for non-numbers. |
| 522 | */ |
| 523 | static int lessthanothers (lua_State *L, const TValue *l, const TValue *r) { |
| 524 | lua_assert(!ttisnumber(l) || !ttisnumber(r)); |
| 525 | if (ttisstring(l) && ttisstring(r)) /* both are strings? */ |
| 526 | return l_strcmp(tsvalue(l), tsvalue(r)) < 0; |
| 527 | else |
| 528 | return luaT_callorderTM(L, l, r, TM_LT); |
| 529 | } |
| 530 | |
| 531 | |
| 532 | /* |
no test coverage detected