From: Nicholas Van Weerdenburg Date: 2005-01-21T03:42:01+09:00 Subject: Re: Confused about variable "declarations" I'm was quite fond of "leaky" since I didn't have a good word for it before. But you are right, I suppose. "leak" is usually a bad thing in boats, birth control, and programming. For instance, who would to apply "leaky logic" algorithms. I can definitely see why they went with "fuzzy logic" instead of "leaky logic". How about "fuzzy scope"? Of course, this could make one think of "cuddly scope", which is also probably accurate when it comes to Ruby (in fact, I noticed one of the Japanese Ruby books on Amazon had a bunny rabbit on it- it was paired with the Ruby Hackers Guide (RBG), so I assume it was Ruby- I don't read or speak Japanese). Of course, if we doing lisp, it would probably be called "transitive dynamic semi-lexical scope transclusion" or something like that ( and no, I have no idea what I just said, if anything). Regards, Nick -- Nicholas Van Weerdenburg On Fri, 21 Jan 2005 02:31:00 +0900, Robert Klemme wrote: > > "Mark Hubbart" schrieb im Newsbeitrag > news:de63abca050120090877cc9971@mail.gmail.com... > > On Thu, 20 Jan 2005 21:01:01 +0900, Graham Nicholls > > wrote: > > > No worries, and thanks, but I think that the problem was that offset > is > > > being set inside an iterator (they still confuse me - any pointers to > a > > > good explanation would be nice!), which means that it is out of scope > > > outside the iterator. > > > > A short explanation: Blocks have a sort of "leaky scope", where > > variables from outside the scope can leak in and out, but those that > > are from the inside don't leak out. for example: > > While I completely agree with your explanation the word "leaky" strikes me > as odd as it seems to suggest uncommon or defective behavior: it's very > common in programming languages, that variables are visible in nested > scopes but not surrounding scopes: > > public int foo() { > int visible_in_whole_method = 0; > > { > int visible_only_in_this_nested_scope = visible_in_whole_method + 1; > } > } > > Kind regards > > robert > >