"as" keyword woes

Aaron Brady castironpi at gmail.com
Wed Dec 10 01:45:03 EST 2008


On Dec 9, 12:40 pm, MRAB <goo... at mrabarnett.plus.com> wrote:
> Aaron Brady wrote:
> > On Dec 9, 8:28 am, MRAB <goo... at mrabarnett.plus.com> wrote:
> > snip
> >> In some languages (I think Delphi is one of them - it's been a while!)
> >> some words which would normally be identifiers have a special meaning in
> >> certain contexts, but the syntax precludes any ambiguity, and not in a
> >> difficult way. "as" in Python was one of those.
>
> >> I certainly wouldn't want something like PL/I, where "IF", "THEN" and
> >> "ELSE" could be identifiers, so you could have code like:
>
> >>      IF IF = THEN THEN
> >>          THEN = ELSE;
> >>      ELSE
> >>          ELSE = IF;
>
> >> Seehttp://en.wikipedia.org/wiki/PL/I_(programming_language).
> > snip
> > That is, 'certainly' doesn't change the meaning of your statement
> > any.  You wouldn't want it, but King George III didn't want the
> > American Revolution.
>
> It's called emphasis.

I just take you to have meant, then, +1 on excluding keywords from
identifiers.  You said it the long way though, so I thought I missed
something deeper, that didn't come across.




More information about the Python-list mailing list