![](https://secure.gravatar.com/avatar/947c14f160f3305b9e7f54c0cc9708a1.jpg?s=120&d=mm&r=g)
Aug. 6, 2005
1:10 a.m.
Robert Kern wrote:
Martijn Faassen wrote:
The svn version only supports deepcopy() as copy.copy() cannot be sensibly supported for lxml, but I guess I should be testing what happens if you do copy.copy.. What *should* happen anyway, anyone have an idea?
According to the documentation:
"""A shallow copy constructs a new compound object and then (to the extent possible) inserts references into it to the objects found in the original."""
I interpret "to the extent possible" meaning that copy.copy() is permitted to do the same as copy.deepcopy() for cases like lxml as long as you document it.
Good point! I'll also implement __copy__(). Okay, done and checked in. Thanks! Martijn