[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: simple local variables question
- From: Norbert Kiesel <nkiesel@...>
- Date: Tue, 16 Jun 2009 14:38:48 -0700
Hi,
is there any real difference between
local a = foo()
-- use a
local a = bar()
-- use a
and
local a = foo()
-- use a
a = bar()
-- use a
luac -l shows me that the first uses another local variable, but
generates shorter code. Assuming I don't go crazy with that (and thus
reach the 200 or so local variable limit): is there any reason not to
use local twice?
</nk>