FelixTheC / strongtyping

Decorator which checks whether the function is called with the correct type of parameters.
https://pypi.org/project/strongtyping/
107 stars 3 forks source link

@match_class_typing decorater disrupts "isintance(obj, Class)" calls #75

Closed Jax89 closed 2 years ago

Jax89 commented 3 years ago

Using @match_class_typing class decorator on a class leads to wrong behavior of "isinstance"

from strongtyping.strong_typing import match_class_typing

@match_class_typing
class A:
    pass

x = A()
assert isinstance(x, A) 

Expected behavior isinstance(x, A) should return True.