[New-bugs-announce] [issue22057] The doc say all globals are copied on eval(), but only __builtins__ is copied
Alon Mishne
report at bugs.python.org
Thu Jul 24 15:59:49 CEST 2014
New submission from Alon Mishne:
According to the documentation of eval():
> If the globals dictionary is present and lacks '__builtins__', the current globals are copied into globals before expression is parsed.
However in practice only the __builtins__ items are copied, see:
http://hg.python.org/cpython/file/2.7/Python/bltinmodule.c#l655
See http://stackoverflow.com/q/24934908/242762
----------
assignee: docs at python
components: Documentation
messages: 223837
nosy: amishne, docs at python
priority: normal
severity: normal
status: open
title: The doc say all globals are copied on eval(), but only __builtins__ is copied
versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4, Python 3.5
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue22057>
_______________________________________
More information about the New-bugs-announce
mailing list