Re:Exposing Python 3.6's Private Dict Version
by _wmd on Sunday May 28, 2017 @08:19PM
(#14436717)
See PyFrame_FastToLocals() in the CPython source.
Try wrapping your code in a function and notice the changes are no longer mirrored. Calls to exec() and eval() cause PyFrame_FastToLocals() to be applied afterwards, as used by the interactive console, but this doesn't happen during normal execution
Try wrapping your code in a function and notice the changes are no longer mirrored. Calls to exec() and eval() cause PyFrame_FastToLocals() to be applied afterwards, as used by the interactive console, but this doesn't happen during normal execution