lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


cynthia powers wrote:
> yes. Thanks! it does appear that my myfile.lua has a syntax error, because
> when I replaced that file with another simpler lua file, it seems to go
> through.
> Is there a way to (auto) check on the syntax of a lua file? the lua file I
> have is "generated" ..
> 
> cynthia.

Please don't top-post.

You can either check the syntax of your file by calling luaL_loadfile
and checking the result to ensure it's 0, or you can run luac on the
file and look for a non-zero return code.

Regards,
-- Matthew P. Del Buono