summaryrefslogtreecommitdiff
path: root/src/lcode.js
diff options
context:
space:
mode:
authorBenoit Giannangeli <giann008@gmail.com>2017-03-12 16:01:08 +0100
committerBenoit Giannangeli <giann@users.noreply.github.com>2017-03-13 11:03:24 +0100
commit4c404c404c281f1872f0283acbaee97657f3e08b (patch)
treea347635408110a0219e494876d9e54542175a645 /src/lcode.js
parent632cf08572b35e8a350ac8b1f9d5bf77fb4e7b95 (diff)
downloadfengari-4c404c404c281f1872f0283acbaee97657f3e08b.tar.gz
fengari-4c404c404c281f1872f0283acbaee97657f3e08b.tar.bz2
fengari-4c404c404c281f1872f0283acbaee97657f3e08b.zip
[Strings] lapi.js, lcode.js, llex.js, lparser.js
Diffstat (limited to 'src/lcode.js')
-rw-r--r--src/lcode.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lcode.js b/src/lcode.js
index fedf1e2..c0ca1ff 100644
--- a/src/lcode.js
+++ b/src/lcode.js
@@ -513,7 +513,7 @@ const luaK_stringK = function(fs, s) {
** are no "precision" problems.
*/
const luaK_intK = function(fs, n) {
- let k = new TValue(CT.LUA_TLNGSTR, `${n}`);
+ let k = new TValue(CT.LUA_TLNGSTR, lua.to_luastring(`${n}`));
let o = new TValue(CT.LUA_TNUMINT, n);
return addk(fs, k, o);
};
@@ -540,7 +540,7 @@ const boolK = function(fs, b) {
** Add nil to list of constants and return its index.
*/
const nilK = function(fs) {
- return addk(fs, new TValue(CT.LUA_TLNGSTR, `null`), new TValue(CT.LUA_TNIL, null));
+ return addk(fs, new TValue(CT.LUA_TLNGSTR, lua.to_luastring(`null`)), new TValue(CT.LUA_TNIL, null));
};
/*