summaryrefslogtreecommitdiff
path: root/src/luaconf.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/luaconf.js')
-rw-r--r--src/luaconf.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/luaconf.js b/src/luaconf.js
index 8e7885c..00663a6 100644
--- a/src/luaconf.js
+++ b/src/luaconf.js
@@ -1,8 +1,10 @@
"use strict";
-const llimit = require('./llimit.js');
const sprintf = require('sprintf-js').sprintf;
+const LUA_MAXINTEGER = 2147483647;
+const LUA_MININTEGER = -2147483648;
+
/*
@@ LUAI_MAXSTACK limits the size of the Lua stack.
** CHANGE it if you need a different limit. This limit is arbitrary;
@@ -28,7 +30,7 @@ const lua_number2str = function(n) {
};
const lua_numbertointeger = function(n) {
- return n >= llimit.MIN_INT && n < -llimit.MIN_INT ? n : false;
+ return n >= LUA_MININTEGER && n < -LUA_MININTEGER ? n : false;
};
const LUA_INTEGER_FRMLEN = "";
@@ -64,14 +66,16 @@ const ldexp = function(mantissa, exponent) {
return result;
};
-module.exports.frexp = frexp;
-module.exports.ldexp = ldexp;
module.exports.LUAI_MAXSTACK = LUAI_MAXSTACK;
module.exports.LUA_IDSIZE = LUA_IDSIZE;
module.exports.LUA_INTEGER_FMT = LUA_INTEGER_FMT;
module.exports.LUA_INTEGER_FRMLEN = LUA_INTEGER_FRMLEN;
+module.exports.LUA_MAXINTEGER = LUA_MAXINTEGER;
+module.exports.LUA_MININTEGER = LUA_MININTEGER;
module.exports.LUA_NUMBER_FMT = LUA_NUMBER_FMT;
module.exports.LUA_NUMBER_FRMLEN = LUA_NUMBER_FRMLEN;
+module.exports.frexp = frexp;
+module.exports.ldexp = ldexp;
module.exports.lua_getlocaledecpoint = lua_getlocaledecpoint;
module.exports.lua_integer2str = lua_integer2str;
module.exports.lua_number2str = lua_number2str;