[Issue 7653] remove "function literals cannot be class members" annoyance
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Mar 2 12:48:11 PST 2014
https://d.puremagic.com/issues/show_bug.cgi?id=7653
--- Comment #6 from timon.gehr at gmx.ch 2014-03-02 12:48:10 PST ---
(In reply to comment #5)
> Regardless of whether the two issues describe different problems, the pull in
> issue 11545 fixes compilation of the code in this issue as well.
1. There are no tests for the case without explicit 'function'.
2. Does it fix the following as well?
class C{
mixin(delegate{
string r;
foreach(x;["a","b","c"]) r~="int "~x~";";
return r;
}());
}
template ID(alias a){ alias ID=a; }
class C{
int x=3;
alias a = ID!(()=>x);
}
static assert(new C().a()==3);
--
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list