summaryrefslogtreecommitdiff
path: root/src/loadlib.js
diff options
context:
space:
mode:
authordaurnimator <quae@daurnimator.com>2018-03-29 02:36:11 +1100
committerdaurnimator <quae@daurnimator.com>2018-03-29 02:36:11 +1100
commitc0308f2401694031b1b09cbd5d8fb3f9312054f2 (patch)
tree7739a2fd4cf1654b255a2826f19dcb190069a393 /src/loadlib.js
parentcf6463724e06075fc608529df92b1bb026fe740e (diff)
downloadfengari-c0308f2401694031b1b09cbd5d8fb3f9312054f2.tar.gz
fengari-c0308f2401694031b1b09cbd5d8fb3f9312054f2.tar.bz2
fengari-c0308f2401694031b1b09cbd5d8fb3f9312054f2.zip
src/defs.js: LUA_VERSUFFIX should only be defined in lualib
Diffstat (limited to 'src/loadlib.js')
-rw-r--r--src/loadlib.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/loadlib.js b/src/loadlib.js
index aa7a372..fce3d57 100644
--- a/src/loadlib.js
+++ b/src/loadlib.js
@@ -11,7 +11,6 @@ const {
LUA_REGISTRYINDEX,
LUA_TNIL,
LUA_TTABLE,
- LUA_VERSUFFIX,
lua_callk,
lua_createtable,
lua_getfield,
@@ -62,6 +61,7 @@ const {
luaL_pushresult,
luaL_setfuncs
} = require('./lauxlib.js');
+const lualib = require('./lualib.js');
const {
luastring_indexOf,
to_jsstring,
@@ -281,7 +281,7 @@ const env = (function() {
** Set a path
*/
const setpath = function(L, fieldname, envname, dft) {
- let nver = `${envname}${LUA_VERSUFFIX}`;
+ let nver = `${envname}${lualib.LUA_VERSUFFIX}`;
lua_pushstring(L, to_luastring(nver));
let path = env[nver]; /* use versioned name */
if (path === undefined) /* no environment variable? */