On Aug 2, 2011, at 11:14 PM, Sean P. DeNigris wrote:

> 
> Pat Maddox-3 wrote:
>> 
>> becomeForward: ?
>> 
> 
> Looks good, but what's the difference between become: and becomeForward: ?

become: swaps the two objects entirely, becomeForward: "replaces" references 
with the argument. Check out the comments. But a basic example would be...

| a b |
a := 'foo'.
b := 'foobar'.
a becomeForward: b.
"a = 'foobar'  b = 'foobar'"

| a b |
a := 'foo'.
b := 'foobar'.
a become: b.
"a = 'foobar'  b = 'foo'"

Reply via email to