closes bpo-27494: Fix 2to3 handling of trailing comma after a generator expression (#3771)

This commit is contained in:
Jakub Stasiak 2017-10-05 09:10:09 +02:00 committed by Benjamin Peterson
parent a8ed11742b
commit af810b35b4
7 changed files with 38 additions and 10 deletions

View file

@ -459,6 +459,13 @@ class TestLiterals(GrammarTest):
self.validate(s)
class TestGeneratorExpressions(GrammarTest):
def test_trailing_comma_after_generator_expression_argument_works(self):
# BPO issue 27494
self.validate("set(x for x in [],)")
def diff(fn, result):
try:
with open('@', 'w') as f: