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

Method expect_non_float

mypyc/analysis/ircheck.py:269–271  ·  view source on GitHub ↗
(self, op: Op, v: Value)

Source from the content-addressed store, hash-verified

267 self.fail(op, f"Float expected (actual type is {v.type})")
268
269 def expect_non_float(self, op: Op, v: Value) -> None:
270 if is_float_rprimitive(v.type):
271 self.fail(op, "Float not expected")
272
273 def expect_primitive_type(self, op: Op, v: Value) -> None:
274 if not isinstance(v.type, RPrimitive):

Callers 2

visit_int_opMethod · 0.95
visit_comparison_opMethod · 0.95

Calls 2

failMethod · 0.95
is_float_rprimitiveFunction · 0.90

Tested by

no test coverage detected