lua-users home
lua-l archive

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


On Tue, Dec 22, 2009 at 1:50 PM, Peter Cawley <lua@corsix.org> wrote:
> Why not? To me (and effectively to the Lua compiler), the following
> two bits of code are equivalent:
> ---------
> local temp = propBag.Position
> temp.z = 10
> ---------
> propBag.Position.z = 10
> ---------
> Hence in both cases, I would want the original propBag to be modified.

i concur.
if you want a copy of the 'Position' object, just add a :copy() method to it

-- 
Javier