MCPcopy Index your code
hub / github.com/RustPython/RustPython / assert_exception_table_increasing

Method assert_exception_table_increasing

Lib/test/test_dis.py:951–961  ·  view source on GitHub ↗
(self, lines)

Source from the content-addressed store, hash-verified

949 return re.sub(r'\b0x[0-9A-Fa-f]+\b', '0x...', text)
950
951 def assert_exception_table_increasing(self, lines):
952 prev_start, prev_end = -1, -1
953 count = 0
954 for line in lines:
955 m = re.match(r' L(\d+) to L(\d+) -> L\d+ \[\d+\]', line)
956 start, end = [int(g) for g in m.groups()]
957 self.assertGreaterEqual(end, start)
958 self.assertGreaterEqual(start, prev_end)
959 prev_start, prev_end = start, end
960 count += 1
961 return count
962
963 def do_disassembly_compare(self, got, expected):
964 if got != expected:

Callers

nothing calls this directly

Calls 3

assertGreaterEqualMethod · 0.80
matchMethod · 0.45
groupsMethod · 0.45

Tested by

no test coverage detected