From: "Hal E. Fulton" Date: 2001-03-16T16:08:14+09:00 Subject: [ruby-talk:12720] Re: FEATURE REQUEST: 'my' local variables Comments below.... Hal ----- Original Message ----- From: Doug Edmunds To: ruby-talk ML ; Sent: Thursday, March 15, 2001 10:40 PM Subject: [ruby-talk:12718] Re: FEATURE REQUEST: 'my' local variables > I an new to Ruby, but there seems to be something > quite wrong with temporary variables inside blocks > having any impact outside the block. That's like asking, "Have you quit beating your wife?" The fact is these aren't temporary variables. They might look like them; some might assume they are; they might sometimes behave as such; but they aren't. Some might even argue they should be; but they aren't. On the other hand, I sympathize with you. The behavior in this case is a little surprising and hard to get used to. The rule I follow for now is: Don't name a block parameter the same as an existing variable unless there is actually a reason to do so. My German teacher once told me, "Learn the language; don't fight it." Of course, Ruby is subject to change. But it should be controlled change. And Matz, IMO, should have 51% of the voting power... :) Hal