On Tuesday, 7 July 2020 at 20:14:19 UTC, IGotD- wrote:

Thank you, that worked and now it picked the correct overloaded function. I don't understand why and it is a bit counter intuitive. Why two template arguments as I'm not even us using U?

If you look at the article

https://dlang.org/articles/templates-revisited.html#specialization

Then it mentioned that (T : T*) would work. Intuitively, then you would think (T : T[]) would work.

Here (T : T[]) is even the example with the correct double[] type as a correct example as well.

https://dlang.org/spec/template.html#parameters_specialization

I'm confused.

Reply via email to