(self, offset: int)
| 305 | return self.insts[self.offset2inst_index[offset] - 1].offset |
| 306 | |
| 307 | def get_inst(self, offset: int): |
| 308 | # Instructions can get moved as a result of EXTENDED_ARGS removal. |
| 309 | # So if "offset" is not in self.offset2inst_index, then |
| 310 | # we assume that it was an instruction moved back. |
| 311 | # We check that assumption though by looking at |
| 312 | # self.code's opcode. |
| 313 | if offset not in self.offset2inst_index: |
| 314 | offset -= instruction_size(self.opc.EXTENDED_ARG, self.opc) |
| 315 | assert self.code[offset] == self.opc.EXTENDED_ARG |
| 316 | return self.insts[self.offset2inst_index[offset]] |
| 317 | |
| 318 | def get_target(self, offset: int, extended_arg: int = 0) -> int: |
| 319 | """ |
no outgoing calls
no test coverage detected