Deprecate self

Vadim Chugunov chega_ at yahoo.com
Wed Apr 18 04:47:29 EDT 2001


"Dave LeBlanc" <whisper at oz.net> wrote in message
news:9bji5k$417$0 at 216.39.170.247...
> Since self is used for every method of every class, isn't it a bit
> redundant? I don't know of another OO language that makes you manually
> carry around the "this"/"self" pointer/reference...

Sure, we could get rid of 'self'.  ...and then immediately invent coding
convention that allows people to distinguish class variables from globals
and locals.  Like 'm_spam'.

When 'self' seems to be too much typing I shorten it to 's'.






More information about the Python-list mailing list