On Fri, 18 Oct 2019 at 14:33, Richard Musil <risa20...@gmail.com> wrote:
> I have no problem with any example you mentioned above, yet I consider 
> proposed meaning for '+' symbol in this PEP context fundamentally different 
> from either "arithmetic" or "concatenation" meaning, used in the previous 
> examples, because it does not only adds, but also changes the values. 
> Technically we can call set union also an "add" operation, yet we use 
> different semantics to express it, for exactly the same reason, it is not 
> "arithmetic" nor, "concatenation", but something different.

IMO, debating the "meaning" of addition, and whether the + operator is
appropriate here, is not the key question. The real questions for me
are whether the update operation is used frequently enough to require
an additional way of spelling it, and whether using the + operator
leads to cleaner more readable code.

I've personally almost never needed the dictionary update operator, so
for me, having a second way of spelling it is probably not going to be
of any real benefit (and may be a net disadvantage, because I'll have
to understand both forms in code I support). I don't really have a
view on whether the operator or the method would result in cleaner
code, but I'd expect that given how rarely I use the operation, a
named method would be easier to follow (for me).

All of the above is just my subjective opinion. Objective information
is likely to only be available by someone looking at a body of real
world code and demonstrating what difference the proposed operator
would make to it (maybe someone did that already - I've not been
following this thread closely).

Paul
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/25ZCKSPNW4FF5HVPLRKRQY32GQXKDURP/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to