<div dir="ltr"><<< Randal said...<br>
Setting "each" to "nil" there does nothing, since you aren't<br>updating the object that was originally in "each".<br>
>>><br>
<br><< Marcus said...<br>
This is a pretty common misconception. It seems to come up once a month. I<br>
wonder why - mostly it's not people who are new to programming, who I would<br>
expect to be unfamiliar with the distinction between an object or value and<br>
the location it is stored in.>><br><br>I was wondering exactly that myself. After my 'doh!' moment, when Randal explained what I was doing wrong, I was trying to work out why I had made the mistake. The conclusion I came to was that I was becoming so used to sending messages to objects, that I had confused myself into thinking that I was somehow sending 'become nil' to the object stored in :each.<br>
<br>Cheers<br>AB<br>
<br>
<br></div>