From: dblack@... Date: 2003-02-06T20:38:18+09:00 Subject: Re: Local variables & blocks Hi -- On Thu, 6 Feb 2003, Brian Candler wrote: > On Thu, Feb 06, 2003 at 09:23:21AM +0900, dblack@candle.superlink.net wrote: > > This is the part I've never understood. Even if you write a method > > with no blocks, you still have to know whether or not you've used a > > variable name. > > Not necessarily, in the case of throw-away temporary variables: But the whole idea of a 'throw-away' name is that you *know* (because you've decided) what you're going to do with it. Having decided that 'i' is a throw-away name, you then know this, and will not use 'i' except in such cases. Many of the drawbacks people describe to the way Ruby handles block variables seem to be based on the idea that there are cases where you don't know what variable names you've used. That's what I find uncompelling as a reason to change the behavior. David -- David Alan Black home: dblack@candle.superlink.net work: blackdav@shu.edu Web: http://pirate.shu.edu/~blackdav