>>>>> Paul Rubin <http://[EMAIL PROTECTED]> (PR) wrote:

>PR> Reinhold Birkenfeld <[EMAIL PROTECTED]> writes:
>>> For a conditional, syntax must be found, and the tradition of Python
>>> design is not to use punctuation for something that can be solved with
>>> keywords.

>PR> Yeah, "if C then A else B" is a ancient tradition stretching from
>PR> Algol-60 to OCAML, and who knows what all else in between.  I'm not
>PR> sure what Guido saw in the "A if C else B" syntax but it's not a big deal.

I suspect it is because "if C then A else B" gives problems in the parser
because it would have difficulty to distinguish this in time from the if
statement. This is because the parser doesn't use a very strong formalism. 

I think language design should prevail over parsing problems, but in this
case it is probably a pragmatic argument that wins.
-- 
Piet van Oostrum <[EMAIL PROTECTED]>
URL: http://www.cs.uu.nl/~piet [PGP 8DAE142BE17999C4]
Private email: [EMAIL PROTECTED]
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to