diff options
author | daurnimator <quae@daurnimator.com> | 2017-11-12 16:01:51 +1100 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-11-12 16:22:28 +1100 |
commit | 5812c42e7bb680592e60454b003f228dfe95869a (patch) | |
tree | b9aecff7655d6089a77bfabd45f81b2b9dc1c528 /src/ldebug.js | |
parent | 542c431989bff3fc3a6687f182a8c61a7861efd9 (diff) | |
download | fengari-5812c42e7bb680592e60454b003f228dfe95869a.tar.gz fengari-5812c42e7bb680592e60454b003f228dfe95869a.tar.bz2 fengari-5812c42e7bb680592e60454b003f228dfe95869a.zip |
Add internal function defs.luastring_cmp for string equality checks
Diffstat (limited to 'src/ldebug.js')
-rw-r--r-- | src/ldebug.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ldebug.js b/src/ldebug.js index 3637b5d..59520c3 100644 --- a/src/ldebug.js +++ b/src/ldebug.js @@ -565,7 +565,7 @@ const luaG_opinterror = function(L, p1, p2, msg) { const luaG_ordererror = function(L, p1, p2) { let t1 = ltm.luaT_objtypename(L, p1); let t2 = ltm.luaT_objtypename(L, p2); - if (t1.join() === t2.join()) + if (defs.luastring_cmp(t1, t2)) luaG_runerror(L, defs.to_luastring("attempt to compare two %s values", true), t1); else luaG_runerror(L, defs.to_luastring("attempt to compare %s with %s", true), t1, t2); |