summaryrefslogtreecommitdiff
path: root/src/llex.js
diff options
context:
space:
mode:
authordaurnimator <quae@daurnimator.com>2017-05-22 16:24:46 +1000
committerdaurnimator <quae@daurnimator.com>2017-05-22 16:24:46 +1000
commit13ba814ab51f43718c1f07680012e6ee7815b16b (patch)
tree68e1e3fe1a00d5b0235b7aa0d543cc14506d3367 /src/llex.js
parentedf9e47120f2098458519628335a7e90b2569b70 (diff)
downloadfengari-13ba814ab51f43718c1f07680012e6ee7815b16b.tar.gz
fengari-13ba814ab51f43718c1f07680012e6ee7815b16b.tar.bz2
fengari-13ba814ab51f43718c1f07680012e6ee7815b16b.zip
Checks for nil and NaN table keys
Diffstat (limited to 'src/llex.js')
-rw-r--r--src/llex.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/llex.js b/src/llex.js
index 998ab0e..5e6b9ec 100644
--- a/src/llex.js
+++ b/src/llex.js
@@ -147,7 +147,7 @@ const save_and_next = function(ls) {
const luaX_newstring = function(ls, str) {
let L = ls.L;
let ts = lstring.luaS_new(L, str);
- let o = ltable.luaH_set(ls.h, new lobject.TValue(defs.CT.LUA_TLNGSTR, ts));
+ let o = ltable.luaH_set(L, ls.h, new lobject.TValue(defs.CT.LUA_TLNGSTR, ts));
if (o.ttisnil()) { /* not in use yet? */
o.setbvalue(true);
} else { /* string already present */