mirror of
https://github.com/python/cpython.git
synced 2025-11-02 14:41:33 +00:00
gh-97922: Run the GC only on eval breaker (#97920)
This commit is contained in:
parent
c66dbddfba
commit
83eb827247
8 changed files with 74 additions and 14 deletions
|
|
@ -277,7 +277,7 @@ def callback(phase, info):
|
|||
frame!
|
||||
"""
|
||||
nonlocal sneaky_frame_object
|
||||
sneaky_frame_object = sys._getframe().f_back
|
||||
sneaky_frame_object = sys._getframe().f_back.f_back
|
||||
# We're done here:
|
||||
gc.callbacks.remove(callback)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue