diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2010-06-30 10:34:53 (GMT) |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2010-06-30 10:34:53 (GMT) |
commit | ce5b6c43bfbd1e016463c92f43c9075f64fafaa6 (patch) | |
tree | bbb68b7c8d03d33a8f4681c37416fdd011cfff81 /Lib | |
parent | 881c1b4c102e9404c10de159a7f01442c2d7224e (diff) | |
download | cpython-ce5b6c43bfbd1e016463c92f43c9075f64fafaa6.zip cpython-ce5b6c43bfbd1e016463c92f43c9075f64fafaa6.tar.gz cpython-ce5b6c43bfbd1e016463c92f43c9075f64fafaa6.tar.bz2 |
Revert r82044, since it changed the semantics of negated imaginary literals.
Before r82044, '-7j' became complex(0.0, -7.0); afterwards it was
complex(-0.0, -7.0). See issue 9011.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_parser.py | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/Lib/test/test_parser.py b/Lib/test/test_parser.py index e52be06..9c73b99 100644 --- a/Lib/test/test_parser.py +++ b/Lib/test/test_parser.py @@ -479,16 +479,6 @@ class CompileTestCase(unittest.TestCase): st = parser.suite('a = "\\u1"') self.assertRaises(SyntaxError, parser.compilest, st) - def test_issue_9011(self): - # Issue 9011: compilation of an unary minus expression changed - # the meaning of the ST, so that a second compilation produced - # incorrect results. - st = parser.expr('-3') - code1 = parser.compilest(st) - self.assertEqual(eval(code1), -3) - code2 = parser.compilest(st) - self.assertEqual(eval(code2), -3) - class ParserStackLimitTestCase(unittest.TestCase): """try to push the parser to/over its limits. see http://bugs.python.org/issue1881 for a discussion |