3 ms·
> Is there any reason not to use a tmp variable (presumably with a better name)? Nope -- shouldn't hurt at all. It's interesting to me that LuaJIT recommends
by haberman 12y ago
> Is there any reason not to use a tmp variable (presumably with a better name)?
Nope -- shouldn't hurt at all.
It's interesting to me that LuaJIT recommends not using temp variables like this because they can hurt optimization for LuaJIT. That's obviously very different than C in almost every way, I just mention it because it was so surprising to me that there is a situation (in any optimized language) where a temp variable could hurt optimization.