You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-------------------------------------------------------------------------- prepares error message for display, for limits exceeded-- * used only in checklimit()------------------------------------------------------------------------functionluaY:errorlimit(fs, limit, what)
localmsg= (fs.f.linedefined==0) andstring.format("main function has more than %d %s", limit, what) orstring.format("function at line %d has more than %d %s", --<---------------- this is LuaY:303fs.f.linedefined, limit, what)
luaX:lexerror(fs.ls, msg, 0)
end
I printed fs.f and found that fs.f.linedefined is nil, but fs.f.lineDefined exists (capital D). If you replace all occurrences of linedefined with the camel case variant, you get the proper error for the script:
I think this qualifies as a bug because I spent a lot of time trying to figure out why I was getting a string.format error when my code never even used that function. The error being shown by Adonis is not helpful enough to determine what's wrong.
Version channel
Stable (Default)
Loader version
No response
What part of Adonis is this related to?
Other
What happened?
I ran this code with
:ss
This happened:
So I took a look inside LuaY:
I printed
fs.f
and found thatfs.f.linedefined
is nil, butfs.f.lineDefined
exists (capital D). If you replace all occurrences oflinedefined
with the camel case variant, you get the proper error for the script:I think this qualifies as a bug because I spent a lot of time trying to figure out why I was getting a
string.format
error when my code never even used that function. The error being shown by Adonis is not helpful enough to determine what's wrong.Device
MAC
Relevant log output
The text was updated successfully, but these errors were encountered: