consider the following function:
    def foo(a,b,c,x):
        pass

The following calls are equivalent:
    foo(1,2,3, x=0)
    foo(*(1,2,3), x=0)
However, since python allows keyword arguments before star-unpacking, you
can also do:
    foo(x=0, *(1, 2, 3))
But removing the unpacking, would result in a syntax error:
     foo(x=0, 1, 2, 3)
This is against the understanding of unpacking, is this intentional?
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/L5TYF3FRT6VLOKAQBVAQ6AQTLFHAX3WM/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to