diff options
author | daurnimator <quae@daurnimator.com> | 2017-05-29 14:13:28 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-05-29 14:35:56 +1000 |
commit | f87a838f498c2ec6536ba813d7ae83bd1e78a506 (patch) | |
tree | 2d8478b46f1a7b4db9a9ee8fe8c25162091395fe /src/lapi.js | |
parent | 5e169fc1ed36d9cef5f021b1b8be8867902dbdbb (diff) | |
download | fengari-f87a838f498c2ec6536ba813d7ae83bd1e78a506.tar.gz fengari-f87a838f498c2ec6536ba813d7ae83bd1e78a506.tar.bz2 fengari-f87a838f498c2ec6536ba813d7ae83bd1e78a506.zip |
luaO_tostring should modify TValue
Diffstat (limited to 'src/lapi.js')
-rw-r--r-- | src/lapi.js | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/lapi.js b/src/lapi.js index 42e87a9..b08f342 100644 --- a/src/lapi.js +++ b/src/lapi.js @@ -654,8 +654,7 @@ const lua_tolstring = function(L, idx) { if (!lvm.cvt2str(o)) { /* not convertible? */ return null; } - /* TODO: this should modify number on the stack */ - return lobject.luaO_tostring(L, o).getstr(); + lobject.luaO_tostring(L, o); } return o.svalue(); }; @@ -669,8 +668,7 @@ const lua_toljsstring = function(L, idx) { if (!lvm.cvt2str(o)) { /* not convertible? */ return null; } - /* TODO: this should modify number on the stack */ - return defs.to_jsstring(lobject.luaO_tostring(L, o).getstr()); + lobject.luaO_tostring(L, o); } return o.jsstring(); }; |