should "self" be changed?

garabik-news-2005-05 at kassiopeia.juls.savba.sk garabik-news-2005-05 at kassiopeia.juls.savba.sk
Tue May 26 16:26:22 EDT 2015


zipher <dreamingforward at gmail.com> wrote:
> Would it be prudent to rid the long-standing "argument" (pun
> unintended) about self and the ulterior spellings of it, by changing
> it into a symbol rather than a name?  
> 
> Something like:
> 
> class MyClass(object):
> 
>     def __init__(@):
>         @.dummy = None

Believe or not, python3 (via Guido's time machine) already anticipated 
this suggestion and you can indeed use a symbol instead of 'self':

class MyClass(object):

   def __init__(ስ):
       ስ.dummy = None

-- 
 -----------------------------------------------------------
| Radovan Garabík http://kassiopeia.juls.savba.sk/~garabik/ |
| __..--^^^--..__    garabik @ kassiopeia.juls.savba.sk     |
 -----------------------------------------------------------
Antivirus alert: file .signature infected by signature virus.
Hi! I'm a signature virus! Copy me into your signature file to help me spread!



More information about the Python-list mailing list