[Issue 9923] [ICE] (interpret.c line 167) with countUntil on Typedef[]
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jun 17 17:30:36 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9923
--- Comment #4 from bearophile_hugs at eml.cc 2013-06-17 17:30:36 PDT ---
(In reply to comment #3)
> It looks to me like a compiler bug:
>
> -----
> struct Typedef(T, T init, string cookie=null)
> {
> private T Typedef_payload = init;
>
> this(T init)
> {
> Typedef_payload = init; // should be allowed AFAIK
> }
>
> mixin Proxy!Typedef_payload;
> }
> -----
>
> Try filing it.
This code is working:
import std.typecons: Proxy;
struct Foo(T, T init, string cookie=null) {
private T bar = init;
this(T init) {
bar = init;
}
mixin Proxy!bar;
}
void main() {
auto f = Foo!(int, 0, "abc")(10);
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list