Given a Fennel program like this:
(λ foo [bar] (print bar))
(foo :bar)
Nfnl compiles the code to produce this Lua program:
-- [nfnl] test.fnl
local function foo(bar)
if (nil == bar) then
_G.error("Missing argument bar on /home/ben/test/test.fnl:1", 2)
else
end
return print(bar)
end
return foo("bar")
If I understand correctly, the absolute path is there because of fecf731. The problem is that if I commit this Lua file to a git repository, and someone else clones the repository, the error message will probably be incorrect on their machine. Even on my machine, if I move the Lua file to some other directory (e.g. /usr/local/bin), the error message will be incorrect.
If I compile the file manually with fennel --compile test.fnl > test.lua, I get:
local function foo(bar)
if (nil == bar) then
_G.error("Missing argument bar on test.fnl:1", 2)
else
end
return print(bar)
end
return foo("bar")
Could Nfnl please do this instead?
Given a Fennel program like this:
Nfnl compiles the code to produce this Lua program:
If I understand correctly, the absolute path is there because of fecf731. The problem is that if I commit this Lua file to a git repository, and someone else clones the repository, the error message will probably be incorrect on their machine. Even on my machine, if I move the Lua file to some other directory (e.g.
/usr/local/bin), the error message will be incorrect.If I compile the file manually with
fennel --compile test.fnl > test.lua, I get:Could Nfnl please do this instead?