Sorry, something went wrong.
|
@scoder @serhiy-storchaka Does this match expectations? |
Sorry, something went wrong.
| """ | ||
| warnings.warn( | ||
| "elem.copy() is deprecated. Use copy.copy(elem) instead.", | ||
| DeprecationWarning |
There was a problem hiding this comment.
Not sure if we should issue a DeprecationWarning straight away (or a PendingDeprecationWarning first), although I personally wouldn't mind, given that the C implementation has shadowed this method for years (in CPython, that is).
@serhiy-storchaka, what do you think?
Sorry, something went wrong.
There was a problem hiding this comment.
FWIW, copy() does not appear in the documentation, either.
Sorry, something went wrong.
There was a problem hiding this comment.
Also, I can't find any record of copy ever having been available in the C implementation; it looks like it was __copy__ from the beginning.
The first appearance of copy in the Python implementation was in f15351d (first released in Python 3.1 and 2.7.4), which deemed it "experimental". 84fae78 (first released in Python 3.4) removed that designation when switching from comments to docstrings.
Sorry, something went wrong.
|
@serhiy-storchaka Any thoughts on this? I think your opinion is the only thing outstanding here. |
Sorry, something went wrong.
https://bugs.python.org/issue32424