-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Closed
Labels
Description
This is not a priority, but probably we could allow subclassing Callable, some people might find this "nicer", than defining a __call__ method (e.g. if this is an ABC or a protocol). For example this already works at runtime:
class C(Callable[[int], int]):
attr: strThis would be implemented by returning CallableType for C with a fallback to an instance of the original TypeInfo (like for tulpes, see also #3831).
Reactions are currently unavailable