Akira Li added the comment:
I don't think this is needed nor do I think that it is a good idea to
have a copy() method in the ABCs because they know so little about
their concrete underlying class (perhaps the backing store in the
filesystem or a database). Besides, a user already has
Guido van Rossum added the comment:
You need to learn when to give up. :-)
I wasn't the one who added a copy() method to other containers. I personally
despise almost all uses of copying (including the entire copy module, both
deep and shallow copy functionality). I much prefer to write
Raymond Hettinger added the comment:
I don't think this is needed nor do I think that it is a good idea to have a
copy() method in the ABCs because they know so little about their concrete
underlying class (perhaps the backing store in the filesystem or a database).
Besides, a user already
Guido van Rossum added the comment:
Agreed with Raymond. The return type of copy() for ABCs feels problematic.
MutableMapping doesn't have it either.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue22101
New submission from Akira Li:
The documentation for standard types says [1]:
clear() and copy() are included for consistency with the interfaces of
mutable containers that don’t support slicing operations (such as dict
and set)
New in version 3.3: clear() and copy() methods.
[1]
Changes by Antoine Pitrou pit...@free.fr:
--
nosy: +gvanrossum, rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue22101
___
___
Changes by Antoine Pitrou pit...@free.fr:
--
nosy: +serhiy.storchaka
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue22101
___
___
Python-bugs-list