""Martin v. Löwis"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Terry Reedy wrote: >> There are two subproposals: first, keyword-only args after a variable >> number of positional args, which requires allowing keyword parameter >> specifications after the *args parameter, and second, keyword-only args >> after a fixed number number of positional args, implemented with a naked >> '*'. To the first, I said "The rationale for this is pretty obvious.". >> To >> the second, I asked, and still ask, "Why?". > > One reason I see is to have keyword-only functions, i.e. with no > positional arguments at all:
This is not a reason for subproposal two, but a special case, as you yourself note below, and hence does say why you want to have such. > def make_person(*, name, age, phone, location): > pass And again, why would you *make* me, the user-programmer, type make_person(name=namex, age=agex, phone=phonex, location = locationx) #instead of make_person(namex,agex,phonex,locationx) ? Ditto for methods. > In these cases, you don't *want* name, age to be passed in a positional > way. I sure you know what I am going to ask, that you did not answer ;-) Terry Jan Reedy PS. I see that Guido finally gave a (different) use case for bare * that does make sense to me.
_______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com