diff options
author | Raymond Hettinger <python@rcn.com> | 2005-02-07 19:32:38 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2005-02-07 19:32:38 (GMT) |
commit | 7fcb7869ba82586f68e0cf28c3a25e78457fa0e0 (patch) | |
tree | aa9eef07f6653ca56676489cd68c4d8bbbbc0bc5 /Lib | |
parent | fe59dc1bd83d769acb47336f3570ec99e6ba16b6 (diff) | |
download | cpython-7fcb7869ba82586f68e0cf28c3a25e78457fa0e0.zip cpython-7fcb7869ba82586f68e0cf28c3a25e78457fa0e0.tar.gz cpython-7fcb7869ba82586f68e0cf28c3a25e78457fa0e0.tar.bz2 |
Adopt Skip's idea to optimize lists of constants in the context
of a "in" or "not in" test.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_peepholer.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/test/test_peepholer.py b/Lib/test/test_peepholer.py index bedf763..0e723eb 100644 --- a/Lib/test/test_peepholer.py +++ b/Lib/test/test_peepholer.py @@ -135,7 +135,8 @@ class TestTranforms(unittest.TestCase): def test_set_conversion(self): for line in ( - 'x in (1,2,3)', + 'x in [1,2,3]', + 'x in (1,2,3)', 'x not in (1,2,3)', 'not x in (1,2,3)', 'not x not in (1,2,3)', |