Is there anyway of making Python methods have access to the class fields/methods without using the self parameter?
It's really annoying having to write self. self. self. self. The code gets so ugly to the point I'm thinking of not using classes anymore purely for code aesthetics. I don't care about the risks or best practices. I just want not to see self anymore.
P.S. I know about the renaming possibility but it's not the point.
s
,other
ornot_self
. :-p – Sabbathlocals()
hacks? – Semiweeklyself
without explicitself
? – Salletattribute = 1
in class scope is that this doesn't declare an instance attribute -- it declares a class attribute, which is different. Instance attributes in Python are not declared statically, they are dynamic. – Sallet