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

Method __init__

mypyc/ir/ops.py:1054–1066  ·  view source on GitHub ↗
(self, items: list[Value], line: int)

Source from the content-addressed store, hash-verified

1052 error_kind = ERR_NEVER
1053
1054 def __init__(self, items: list[Value], line: int) -> None:
1055 super().__init__(line)
1056 self.items = items
1057 # Don't keep track of the fact that an int is short after it
1058 # is put into a tuple, since we don't properly implement
1059 # runtime subtyping for tuples.
1060 self.tuple_type = RTuple(
1061 [
1062 arg.type if not is_short_int_rprimitive(arg.type) else int_rprimitive
1063 for arg in items
1064 ]
1065 )
1066 self.type = self.tuple_type
1067
1068 def sources(self) -> list[Value]:
1069 return self.items.copy()

Callers

nothing calls this directly

Calls 3

RTupleClass · 0.90
is_short_int_rprimitiveFunction · 0.90
__init__Method · 0.45

Tested by

no test coverage detected