summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2024-04-27 00:25:31 +0800
committerruki <[email protected]>2024-04-27 00:25:31 +0800
commitf4ccb1825049d7ec8f0df5e333cce7e7fd86cca7 (patch)
treeba61fa5f279dbaa4eb90fdff3e6926249bab122d
parentb127a7d00eadcd5f21abfdc71e28dc55a6363d7b (diff)
improve bcsave
-rw-r--r--xmake/core/sandbox/modules/import/lib/luajit/bcsave.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/xmake/core/sandbox/modules/import/lib/luajit/bcsave.lua b/xmake/core/sandbox/modules/import/lib/luajit/bcsave.lua
index 3f88155cc..a23523b4d 100644
--- a/xmake/core/sandbox/modules/import/lib/luajit/bcsave.lua
+++ b/xmake/core/sandbox/modules/import/lib/luajit/bcsave.lua
@@ -23,6 +23,10 @@ local io = require("base/io")
local string = require("base/string")
local raise = require("sandbox/modules/raise")
+if not xmake._LUAJIT then
+ return
+end
+
-- save lua file to bitcode file
--
-- @param luafile the lua file
@@ -45,6 +49,4 @@ function main(luafile, bcfile, opt)
end
end
-if xmake._LUAJIT then
- return main
-end
+return main