[Issue 15225] cannot overload directly aliased function literals
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Tue Oct 27 02:11:07 PDT 2015
https://issues.dlang.org/show_bug.cgi?id=15225
Vladimir Panteleev <thecybershadow at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |thecybershadow at gmail.com
--- Comment #1 from Vladimir Panteleev <thecybershadow at gmail.com> ---
(In reply to Kenji Hara from comment #0)
> alias foo = (int x) => x;
> alias foo = (string x) => x;
This syntax doesn't work in released DMD versions, but if I replace it with:
alias I(alias X) = X;
alias foo = I!((int x) => x);
alias foo = I!((string x) => x);
then compilation succeeds (though then I get a linker error).
--
More information about the Digitalmars-d-bugs
mailing list