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

Class MyArgResolver

Lib/test/test_dis.py:2226–2231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2224
2225 def test_custom_arg_resolver(self):
2226 class MyArgResolver(dis.ArgResolver):
2227 def offset_from_jump_arg(self, op, arg, offset):
2228 return arg + 1
2229
2230 def get_label_for_offset(self, offset):
2231 return 2 * offset
2232
2233 def f(opcode, oparg, offset, *init_args):
2234 arg_resolver = MyArgResolver(*init_args)

Callers 1

fMethod · 0.85

Calls

no outgoing calls

Tested by 1

fMethod · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…