Redefining class methods
shochet at my-deja.com
shochet at my-deja.com
Thu Aug 24 21:00:26 EDT 2000
Is there an easy way (maybe within emacs mode) to redefine a class
method without redefining the class? The problem with completely
redefining the entire class is that all the objects created with the
old class are now stale.
I know one way is to modify the class dictionary by hand:
def newmethod(self): pass
Class['method'] = newmethod
But this is a quite a burden to overcome every time you tweak some
class method when trying to rapid prototype. I know Smalltalk does this
very well and I miss it...
Sent via Deja.com http://www.deja.com/
Before you buy.
More information about the Python-list
mailing list