[Issue 18520] Different delegates can be aliased to the same name multiple times
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Feb 25 05:02:32 UTC 2018
https://issues.dlang.org/show_bug.cgi?id=18520
Basile B. <b2.temp at gmx.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |INVALID
--- Comment #2 from Basile B. <b2.temp at gmx.com> ---
This due to implicit conversion which has for effect to make the first overload
always working.
a way to overcome this:
alias f(T = int) = (T n) => 0;
alias f(T = char) = (T n) => 'a';
alias f(T = bool) = (T n) => false;
--
More information about the Digitalmars-d-bugs
mailing list