Template Usage with Eponymous Trick
Steven Schveighoffer
schveiguy at gmail.com
Fri Jan 31 15:37:06 UTC 2020
On 1/30/20 9:10 AM, ShadoLight wrote:
> Why does the 'classical' template calling convention not work anymore in
> this case? (if the template name and function name are different it
> obviously still works). Note the templates were not defined in the
> simplified 'Eponymous Trick' style i.e.:
>
I know your question is pretty much answered, but to give you some
historical perspective, the long form WAS allowed in the past (it may
still be that way in D1), and I think there were ambiguity problems as
described. So you can no longer do that.
It was actually much more restrictive before -- e.g. in order to do an
eponymous template, you could have no other members in the template.
Probably we should adjust the examples to remove those that no longer work.
-Steve
More information about the Digitalmars-d-learn
mailing list