MCPcopy Index your code
hub / github.com/python/mypy / get_method_hook

Method get_method_hook

mypy/plugin.py:671–677  ·  view source on GitHub ↗

Adjust return type of a method call. This is the same as get_function_hook(), but is called with the method full name (again, using the class where the method is defined).

(self, fullname: str)

Source from the content-addressed store, hash-verified

669 return None
670
671 def get_method_hook(self, fullname: str) -> Callable[[MethodContext], Type] | None:
672 """Adjust return type of a method call.
673
674 This is the same as get_function_hook(), but is called with the
675 method full name (again, using the class where the method is defined).
676 """
677 return None
678
679 def get_attribute_hook(self, fullname: str) -> Callable[[AttributeContext], Type] | None:
680 """Adjust type of an instance attribute.

Callers 3

apply_function_pluginMethod · 0.45
check_callable_callMethod · 0.45
get_method_hookMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected