Template Usage with Eponymous Trick
ShadoLight
ettienne.gilbert at gmail.com
Mon Feb 3 00:53:10 UTC 2020
On Sunday, 2 February 2020 at 23:48:45 UTC, Paul Backus wrote:
> On Sunday, 2 February 2020 at 23:39:10 UTC, ShadoLight wrote:
>> But, my question was if this was avoidable if braces were not
>> optional. Paul's answer was that non-optional braces will not
>> make...
>> alias a = S!(int);
>> ... non-ambiguous, but I still don't get that based on the
>> above results.
[..]
> If the behavior were changed as you have previously proposed,
> so that `S!(int)` could refer *either* to the eponymous struct
> *or* the template instance, then the alias declaration would
> become ambiguous. Again, this would be true whether or not you
> used braces.
Ok, I get it. Thanks.
More information about the Digitalmars-d-learn
mailing list