◐ Shell
clean mode source ↗

Message 306209 - Python tracker

On Tue, Nov 14, 2017 at 01:31:52PM +0000, Nick Coghlan wrote:
> If limited to the original scope, this isn't a new special case, it's fixing a bug in the implementation of the existing special case (where it's ignoring the trailing comma when it shouldn't be).

This ignores the trailing comma:

    f([1,2,3],)

And this:

    f(x for x in [1,2,3],)

Seems logical to me.

Do you want to allow the 1,2 to be read as a tuple?

   f(x for x in 1,2)