Proposal for removing self
Sean Ross
sross at connectmail.carleton.ca
Thu Aug 26 18:54:38 EDT 2004
"Ravi Teja Bhupatiraju" <webraviteja at yahoo.com> wrote in message
> __readonly__ would be another nicety.
Well, you could use this for __readonly__ (though I named it 'readable()'):
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/157768
or if you want to use meta-classes (and this recipe does use __readonly__):
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/197965
There are many similar implementations floating around.
As for removing self:
http://starship.python.net/crew/mwh/hacks/selfless.py
Enjoy,
Sean
More information about the Python-list
mailing list