On Sun, May 20, 2018 at 1:35 AM, Steven D'Aprano <st...@pearwood.info>
wrote:

>
> but maybe when languages are weird enough they all look the same :-)
>

>
https://www.dreamsongs.com/WorseIsBetter.html

Look at what happened with PERL...

IMPORTANT NOTE:

Enabling "as" in "if" and "while"  doesn't have to be at the expense of
some form of assignment expression. We've been having this discussion as if
has to be either one or the other, and there's no reason we can't have both
(as mentioned before, "reduce()"  is live and well in the libraries, for
people who need to use it).

I in particular would not like it at all if something like ":="  was at the
expense of "as", and I think that others on the side of expanding "if" and
"while" may feel the same way.

As a reminder, some of the arguments in favor of "as" are around the
patterns exemplified by the "re" module; patterns which seem correct and
useful, and that are used by other standard and 3rd-party modules.

if os.fork() as child_pid:

    parent(child_pid)

else:

   child()




Cheers!

-- 
Juancarlo *Añez*
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to