From: Kevin Smith Date: 2000-12-23T13:59:15+09:00 Subject: [ruby-talk:7989] Re: defined? problem? Dave Thomas wrote: >Kevin Smith writes: > >> Hold it right there. Is it really valid to >> "remember the fact that m is a variable"? It >> seems like that decision should be held off until >> runtime. > >Well, what happens is not that it remembers that m is a variable, but >that it has seen m being treated as a variable. > >Holding it off until runtime also leads to undesirable side-effects. > >My feeling here is that we're making a compromise. For the convenience >of allowing parameterless method calls without parentheses, we >occasionally force the interpreter to silently resolve ambiguities >during the parse. I guess another 'convenience' that is confusing things is allowing if-modifiers after the code, which I still don't like. I won't use them in my code, and this is yet another reason. For me, saying 'a if b' is like those instructions for putting together a desk that say: 1) Glue part x to part y. 2) Before doing that, be sure to insert tab a into slot b. By the time I see what I should have done before I did it, it's too late and I've already done it. Obviously perl-folk are used to that construct and have no problem with it. For me, it's just too weird. Kevin