diff options
author | daurnimator <quae@daurnimator.com> | 2017-05-22 16:24:46 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-05-22 16:24:46 +1000 |
commit | 13ba814ab51f43718c1f07680012e6ee7815b16b (patch) | |
tree | 68e1e3fe1a00d5b0235b7aa0d543cc14506d3367 /src/llex.js | |
parent | edf9e47120f2098458519628335a7e90b2569b70 (diff) | |
download | fengari-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.js | 2 |
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 */ |