summaryrefslogtreecommitdiff
path: root/src/lvm.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/lvm.js')
-rw-r--r--src/lvm.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lvm.js b/src/lvm.js
index 83feb9b..0081376 100644
--- a/src/lvm.js
+++ b/src/lvm.js
@@ -973,8 +973,8 @@ const tostring = function(L, i) {
if (o.ttisstring()) return true;
- if (cvt2str(o) && !isNaN(o.value)) {
- L.stack[i] = new lobject.TValue(CT.LUA_TLNGSTR, lstring.luaS_bless(L, defs.to_luastring(`${o.value}`)));
+ if (cvt2str(o)) {
+ L.stack[i] = lobject.luaO_tostring(L, o);
return true;
}