summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_descrtut.py
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2004-07-02 06:41:07 (GMT)
committerRaymond Hettinger <python@rcn.com>2004-07-02 06:41:07 (GMT)
commit214b1c3aaea3e83302df9ea37a37b3c7548b92b1 (patch)
tree4ddeda01308aec48c7edda3188a4aad84dc9435b /Lib/test/test_descrtut.py
parent78bace7442bb89aa005950a1e37f71d4704d4cb6 (diff)
downloadcpython-214b1c3aaea3e83302df9ea37a37b3c7548b92b1.zip
cpython-214b1c3aaea3e83302df9ea37a37b3c7548b92b1.tar.gz
cpython-214b1c3aaea3e83302df9ea37a37b3c7548b92b1.tar.bz2
SF Bug #215126: Over restricted type checking on eval() function
The builtin eval() function now accepts any mapping for the locals argument. Time sensitive steps guarded by PyDict_CheckExact() to keep from slowing down the normal case. My timings so no measurable impact.
Diffstat (limited to 'Lib/test/test_descrtut.py')
-rw-r--r--Lib/test/test_descrtut.py10
1 files changed, 0 insertions, 10 deletions
diff --git a/Lib/test/test_descrtut.py b/Lib/test/test_descrtut.py
index 58b7451..851ce4a 100644
--- a/Lib/test/test_descrtut.py
+++ b/Lib/test/test_descrtut.py
@@ -78,16 +78,6 @@ statement or the built-in function eval():
3
>>>
-However, our __getitem__() method is not used for variable access by the
-interpreter:
-
- >>> exec "print foo" in a
- Traceback (most recent call last):
- File "<stdin>", line 1, in ?
- File "<string>", line 1, in ?
- NameError: name 'foo' is not defined
- >>>
-
Now I'll show that defaultdict instances have dynamic instance variables,
just like classic classes: