The proposal is to eliminate the redundancy of writing name=name
repeatedly. But IMHO it doesn't do that consistently. That is it allows
both forms mixed together, e.g.,

f(*, a, b, c=x, d, e)

I believe this is confusing in part because the * need not be near the
arguments it affects. Consider

open(*, name='temp.txt', mode='r', buffering=-1, encoding='utf-8', errors)

By the time you get to the last arg, you'll have forgotten the * at the
beginning. If Python were to adopt a syntax to address this, I think it
should be something like

f(=a, =b, c=x, =d, =e)
open(name='temp.txt', mode='r', buffering=-1, encoding='utf-8', =errors)

Where an = in an argument list without a name in front of it uses the
symbol on the right hand side as the name.

--- Bruce
_______________________________________________
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