DIP 1019--Named Arguments Lite--Final Review

a11e99z black80 at bk.ru
Fri Aug 23 19:38:20 UTC 2019


On Friday, 23 August 2019 at 19:33:07 UTC, Dennis wrote:
> On Friday, 23 August 2019 at 19:30:40 UTC, Dennis wrote:
>> ```
>> import std.stdio;
>> void foo(int a, double b) {writeln("0");}
>> void foo(int b, int a) {writeln("1");}
>>
>> void main()
>> {
>>     foo(b: 10, 0);
>> }
>> ```
>
> Correction:
> ```
> import std.stdio;
> void foo(int a, int b) {writeln("0");}
> void foo(int b, double a) {writeln("1");}
> void main()
> {
>     foo(b: 10, 0);
> }
> ```
>
> The point is, is an exact type match more important than 
> parameter order match?

as I said 
https://forum.dlang.org/post/wlcwgrfotdfpojbtktne@forum.dlang.org
- named args follows by unnamed args, not vice versa, no mixing


More information about the Digitalmars-d mailing list