lua-users home
lua-l archive

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


When using C(-alike scripting) language(s), I really like the += "feature".

But I really got that lua gets much more complicated, like Jerome already said.

Why don't you just use a add function or something like this? Is very little amount of extra letters and keeps everything clear to understand, too.

Instead of the wanted var1 += newvar1 then you use inc(var1,newvar1) with var1 beeing a call by reference (so after calling, var1 = var1 + newvar1).

But I must addmit, that I am not that fimilar with possibilities to call by reference with numbers in lua (in a table its a default).

Kind regards,

 Jan (DracoBlue)

___________________________

  http://dracoblue.net