[Python-ideas] Null coalescing operator
Guido van Rossum
gvanrossum at gmail.com
Tue Nov 1 23:59:59 EDT 2016
On Nov 1, 2016 8:10 PM, "Chris Angelico" <rosuav at gmail.com> wrote:
> On Wed, Nov 2, 2016 at 11:09 AM, Steven D'Aprano <steve at pearwood.info>
> > I don't know when I would ever want to actually do this in practice, but
> > allowing the ?. operator to magically effect code outside of the
> > parentheses definitely counts as "spooky action at a distance". Guido's
> > rule of "everything to the right" is easy to reason about if "to the
> > right" ends where the parenthised expression ends.
> We already expect "to the left" and "to the right" to end based on
> operator precedence rules. Parentheses are used to control operator
> precedence. It would surprise people *greatly* if they didn't bound
> the effect of the question mark.
> Python-ideas mailing list
> Python-ideas at python.org
> Code of Conduct: http://python.org/psf/codeofconduct/
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-ideas