On 2019-06-04 14:34, Ricky Teachey wrote:
"update an object with another" (dunder update)

Yes, that's essentially what I meant. To me, "assign an object in place" and "update an object with another" mean the same thing.

A few come to mind:

my_dict.update

This is PEP 584, where += is used

my_gen.send

Sure, this makes sense to me!

my_list.append

I disagree because this keeps the contents of the old list.

my_list.extend

This should just be a generalization of the += operator.

my_stream.write

I'm not convinced. If you have an operator for writing, you expect an operator for reading too. But then, the analogy with += breaks down for me.
_______________________________________________
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