Copy constructors
Terry Reedy
tjreedy at home.com
Sat Aug 18 13:09:37 EDT 2001
I am in general opposed to breaking code by deleting features in use,
but I also don't like core dumps or (in Windows) blue-screen-forced
reboots. If the necessary restrictions on __class__ arising from the
redesign of types and classes bind one too tightly, there will still
be, I believe, the option of giving a class an (assignable)
__varclass__ slot (which will effectively replace __class__) accessed
thru __getattr__. As I pointed out nearly 5 years ago in
http://groups.google.com/groups?selm=57ff5e%24cs2%40news.udel.edu
(Note: when you do a search thru google, there will be a
representation of the search parameters between '/' and 'selm' that
can be tossed to access articly directly)
Python is increadibly flexible: you can even, for instance, have
instances inheriting from each other. Restriction on __class__
reassignment will not take this away.
Terry J. Reedy
More information about the Python-list
mailing list