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

Method current_function_name

mypy/scope.py:53–55  ·  view source on GitHub ↗

Return the current function's short name if it exists

(self)

Source from the content-addressed store, hash-verified

51 return self.classes[-1].name if self.classes else None
52
53 def current_function_name(self) -> str | None:
54 """Return the current function's short name if it exists"""
55 return self.function.name if self.function else None
56
57 @contextmanager
58 def module_scope(self, prefix: str) -> Iterator[None]:

Callers 2

reportMethod · 0.80
visit_decoratorMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected