MCPcopy
hub / github.com/python/mypy / record_definition

Method record_definition

mypy/partially_defined.py:107–110  ·  view source on GitHub ↗
(self, name: str)

Source from the content-addressed store, hash-verified

105 )
106
107 def record_definition(self, name: str) -> None:
108 assert len(self.branches) > 0
109 self.branches[-1].must_be_defined.add(name)
110 self.branches[-1].may_be_defined.discard(name)
111
112 def delete_var(self, name: str) -> None:
113 assert len(self.branches) > 0

Callers 8

record_definitionMethod · 0.45
__init__Method · 0.45
process_definitionMethod · 0.45
visit_for_stmtMethod · 0.45
visit_name_exprMethod · 0.45
visit_importMethod · 0.45
visit_import_fromMethod · 0.45
visit_type_alias_stmtMethod · 0.45

Calls 3

lenFunction · 0.85
discardMethod · 0.80
addMethod · 0.45

Tested by

no test coverage detected