DIP 1030--Named Arguments--Community Review Round 1 Discussion

Manu turkeyman at gmail.com
Tue Feb 11 07:40:12 UTC 2020


On Mon, Feb 10, 2020 at 4:45 PM Adam D. Ruppe via Digitalmars-d
<digitalmars-d at puremagic.com> wrote:
>
> On Tuesday, 11 February 2020 at 00:03:01 UTC, aliak wrote:
> > I do agree that having something like
> > ParametersWithNamesAndDefaultArgs is infeasible.
>
> I posted this earlier in this very thread:
>
> https://forum.dlang.org/post/cfcgecteoeynumsamjwe@forum.dlang.org
>
> It is not only feasible... but trivial.
> ParametersWithNamesAndDefaultArgs is a *built-in language
> feature* - see 5.6 under here
> https://dlang.org/spec/expression.html#IsExpression
>
> Forwarding this stuff is not difficult at all.

Sorry, I missed that above. Thanks for pointing this out.
I did not realise __parameters populated the tuple with all that
information... it's not even clear to me how that works!

What manner of 'thing' exists in a tuple that can be a type, but also
have a name and a default value associated with it?
Whatever kind of thing the elements in the tuple are; this seems very
useful, and I wanna know how to deploy this kind of thing generally.
I don't even know what to call this... it's not a 'type' or a 'value',
what 'kind of thing' is this?
I guess it's a declaration alias. I wonder how this syntax is useful
elsewhere...


More information about the Digitalmars-d mailing list