[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Convenient undefined variable checking script
- From: Jorge <xxopxe@...>
- Date: Wed, 23 Jan 2013 11:26:27 -0200
On 01/23/2013 08:30 AM, steve donovan wrote:
Hi all,
This is an extended version of David Manura's globalsplus.lua
described in http://lua-users.org/wiki/DetectingUndefinedVariables
Here is a fragment culled from a program:
------------------------------
local opts={}
if opts["h"] then
os.exit ()
end
if not opts["gogo"] then
end
------------------------------
It gives me:
$ lua globalsplus.lua t.lua
globals: t.lua:5: undefined get os.exit.gogo
If I remove the second "if", everything is ok.
Is that interesting?
Jorge