MCPcopy Index your code
hub / github.com/python/cpython / update_target

Method update_target

Tools/jit/_optimizers.py:115–119  ·  view source on GitHub ↗
(self, target: str)

Source from the content-addressed store, hash-verified

113 return self.kind in (InstructionKind.LONG_BRANCH, InstructionKind.SHORT_BRANCH)
114
115 def update_target(self, target: str) -> "Instruction":
116 assert self.target is not None
117 return Instruction(
118 self.kind, self.name, self.text.replace(self.target, target), target
119 )
120
121 def update_name_and_target(self, name: str, target: str) -> "Instruction":
122 assert self.target is not None

Callers 3

_invert_hot_branchesMethod · 0.80

Calls 2

InstructionClass · 0.70
replaceMethod · 0.45

Tested by

no test coverage detected