diff options
author | daurnimator <quae@daurnimator.com> | 2017-05-24 15:39:39 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-05-24 15:45:33 +1000 |
commit | cf49a091eb7f6ec652d12aca5174a4c0ab30db46 (patch) | |
tree | ce151738dd0f1487d01e218c32ea256acfbd4b88 /src | |
parent | b56f0ec3154d8644ed5c62cd7a4aee7139874c1c (diff) | |
download | fengari-cf49a091eb7f6ec652d12aca5174a4c0ab30db46.tar.gz fengari-cf49a091eb7f6ec652d12aca5174a4c0ab30db46.tar.bz2 fengari-cf49a091eb7f6ec652d12aca5174a4c0ab30db46.zip |
src/lapi.js: use .setfrom() when setting a TValue from a TValue
Diffstat (limited to 'src')
-rw-r--r-- | src/lapi.js | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/lapi.js b/src/lapi.js index ae9fa89..44ed1ad 100644 --- a/src/lapi.js +++ b/src/lapi.js @@ -567,11 +567,8 @@ const lua_setupvalue = function(L, funcindex, n) { if (aux) { let name = aux.name; let val = aux.val; - L.top--; - val.type = L.stack[L.top].type; - val.value = L.stack[L.top].value; - + val.setfrom(L.stack[L.top]); return name; } return null; |