54 def __getattr__(self, key):
55 return key
56
57 def get_i(): 58 return ImaginaryNumber()
59
60
A method which should have the bound instance as first argument has no argument defined. Python will throw an error when you'll try to call this method.
class Cls:
def some_method():
...
@classmethod
def something():
...
class Cls:
def some_method(self):
...
@classmethod
def something(cls):
...