I have an object which defines a __deepcopy__
method. I would like a function that will deepcopy it not by the method given by it, but in the default way that objects of the class object
are copied.
How could I do that? I think I could try to code it but there are probably many "gotchas" I won't be thinking of.
The reason I'm doing it is because I have an object class which implements a __deepcopy__
method, and that method checks for some condition, and in some cases it will deepcopy the object in a certain way, and in other cases it will deepcopy in the default object
way.