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

Method stackref_steal

Tools/cases_generator/generators_common.py:412–430  ·  view source on GitHub ↗
(
        self,
        tkn: Token,
        tkn_iter: TokenIterator,
        uop: CodeSection,
        storage: Storage,
        inst: Instruction | None,
    )

Source from the content-addressed store, hash-verified

410 return True
411
412 def stackref_steal(
413 self,
414 tkn: Token,
415 tkn_iter: TokenIterator,
416 uop: CodeSection,
417 storage: Storage,
418 inst: Instruction | None,
419 ) -> bool:
420 self.out.emit(tkn)
421 tkn = next(tkn_iter)
422 assert tkn.kind == "LPAREN"
423 self.out.emit(tkn)
424 name = next(tkn_iter)
425 self.out.emit(name)
426 if name.kind == "IDENTIFIER":
427 return self.stackref_kill(name, storage, False)
428 rparen = emit_to(self.out, tkn_iter, "RPAREN")
429 self.emit(rparen)
430 return True
431
432 def sync_sp(
433 self,

Callers

nothing calls this directly

Calls 3

emitMethod · 0.95
stackref_killMethod · 0.95
emit_toFunction · 0.85

Tested by

no test coverage detected