summaryrefslogtreecommitdiff
path: root/otfl-basics-gen.lua
diff options
context:
space:
mode:
Diffstat (limited to 'otfl-basics-gen.lua')
-rw-r--r--otfl-basics-gen.lua7
1 files changed, 3 insertions, 4 deletions
diff --git a/otfl-basics-gen.lua b/otfl-basics-gen.lua
index 288cfa2..727086e 100644
--- a/otfl-basics-gen.lua
+++ b/otfl-basics-gen.lua
@@ -280,10 +280,9 @@ function caches.compile(data,luaname,lucname)
if d and d ~= "" then
local f = io.open(lucname,'w')
if f then
- local s = loadstring(d)
- if s then
- f:write(string.dump(s,true))
- end
+ local s
+ if _G["loadstring"] then s=loadstring(d) else s=load(d) end
+ f:write(string.dump(s))
f:close()
end
end