Closed rdawemsys closed 8 years ago
hi, finally I understand the reason of these "filling empty files by something" fixes. thanks! and I think it is reasonable to fix empty files to make lualint happy. but I have 1 question. these files causes error when executed by lua 5.1 or luajt 2.1.0, like following:
dokyougemusu-no-MacBook-Pro:test iyatomi$ cat test.lua
+-- Intentionally blank
dokyougemusu-no-MacBook-Pro:test iyatomi$ luajit-2.1.0-alpha test.lua
luajit-2.1.0-alpha: test.lua:1: unexpected symbol near '+'
dokyougemusu-no-MacBook-Pro:test iyatomi$ lua -v
Lua 5.1.5 Copyright (C) 1994-2012 Lua.org, PUC-Rio
dokyougemusu-no-MacBook-Pro:test iyatomi$ lua test.lua
lua: test.lua:1: unexpected symbol near '+'
is there any reason for putting + as first character? if I remove + from files, it never raise error both for lua and luajit. if no special reason, I think this is better way to fix empty files.
dokyougemusu-no-MacBook-Pro:test iyatomi$ cat test.lua
-- Intentionally blank
dokyougemusu-no-MacBook-Pro:test iyatomi$ luajit-2.1.0-alpha test.lua
dokyougemusu-no-MacBook-Pro:test iyatomi$ lua test.lua
The +
as first character is only in the diffs shown by Github.
If you look at the files checked into git, the lines start with --
. E.g.: https://github.com/MessageSystems/lua-aws/blob/fb6114b2ab793d1c4d4e4e1159242b99114ca7a8/lua-aws/requests/rest_json.lua
Thanks for the quick reply, and considering this change!
sorry for stupid question. so there seems no problem for the change. I will merge this.
Some of the files will fail with lualint, because they are empty. Add a comment to each empty file, that it is intentionally empty.
This extends a similar change in @ahpeterson 's fork of lua-aws.