[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Assign idiom
- From: "Mark Edgar" <medgar123@...>
- Date: Thu, 8 Mar 2007 11:27:29 -0700
On 3/8/07, Leigh McRae <leigh.mcrae@cogeco.ca> wrote:
function SetIdiom(tb, v)
tb = v
return v
end
local sp = SetIdiom( self.spBackGround, W_TextRegion() )
This will not work. tb is local to the function body; modifying it
does not modify the actual argument.
The following will work:
function set(t,k,v)
t[k] = v
return v
end
local sp = set( self, "spBackGround", W_TextRegion() )
-Mark