DIP 1020--Named Parameters--Community Review Round 2
rikki at cattermole.co.nz
Tue Sep 24 17:15:51 UTC 2019
On 25/09/2019 3:49 AM, Dukc wrote:
> On Tuesday, 10 September 2019 at 09:06:23 UTC, Mike Parker wrote:
>> This is the feedback thread for the second round of Community Review
>> for DIP 1020, "Named Parameters"
> You're forbidding calling a function with a positional argument coming
> after a named argument, except when the order is exactly the same as in
> the function definition. I don't think that's a good idea, because it
> makes order of the named parameters relevant. That may make the function
> complex to ABI mangle, and prevents function definer from freely
> reordering named parameters afterwards. I think you should either:
That's not true.
The order is relative to the other named parameters except when no
positional arguments follow.
This DIP does not change ABI mangling since named parameters do not get
mangled (they also don't get considered for overload resolution so that
makes it possible).
> -require named arguments to come last in the call (and perhaps the
> corresponding parameters in the function definition)
> -allow a positional argument to come last in any case. The caller may
> stick named arguments anywhere in the argument list, only exception
> being that named parameter can't be passed by UFCS.
> Otherwise I like this. The best named argument proposal in the reviews
> so far.
Thanks, however Walter has killed this DIP so that's that I'm afraid.
More information about the Digitalmars-d