The following program
class decorator:
def __init__(self,f):
self.f=f
def __call__(self):
print ('decorated')
self.f()
def func():
print('Hi')
func()
print("-----------------")
d = decorator(func)
d()
outputs
Hi
-----------------
decorated
Hi
I see nothing strange such an output.