Raymond Hettinger added the comment:

What you're seeing is a feature of the grammar.

Function allow an optional trailing comma in the argument list:

    >>> pow(2, 5)
    32
    >>> pow(2, 5,)
    32

So, to create a tuple inside in an argument list, you need the extra layer of 
parentheses.

Sorry, this isn't a real bug.  It is just a conflict resolution between use of 
a comma to separate arguments in a function call and use of a comma to create a 
tuple.

----------
nosy: +rhettinger
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue30086>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to