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

Method invoke

Tools/gdb/libpython.py:2175–2199  ·  view source on GitHub ↗
(self, args, from_tty)

Source from the content-addressed store, hash-verified

2173
2174
2175 def invoke(self, args, from_tty):
2176 name = str(args)
2177
2178 frame = Frame.get_selected_python_frame()
2179 if not frame:
2180 print('Unable to locate python frame')
2181 return
2182
2183 pyop_frame = frame.get_pyop()
2184 while True:
2185 if not pyop_frame:
2186 print(UNABLE_READ_INFO_PYTHON_FRAME)
2187 break
2188 if pyop_frame.is_shim():
2189 break
2190
2191 sys.stdout.write('Locals for %s\n' % (pyop_frame.co_name.proxyval(set())))
2192
2193 for pyop_name, pyop_value in pyop_frame.iter_locals():
2194 print('%s = %s'
2195 % (pyop_name.proxyval(set()),
2196 pyop_value.get_truncated_repr(MAX_OUTPUT_LEN)))
2197
2198
2199 pyop_frame = pyop_frame.previous()
2200
2201PyLocals()

Callers

nothing calls this directly

Calls 10

strFunction · 0.85
setFunction · 0.85
get_pyopMethod · 0.80
is_shimMethod · 0.80
writeMethod · 0.45
proxyvalMethod · 0.45
iter_localsMethod · 0.45
get_truncated_reprMethod · 0.45
previousMethod · 0.45

Tested by

no test coverage detected