[Issue 402] New: compiler crash with mixin and forward reference

Thomas Kuehne thomas-dloop at kuehne.cn
Fri Oct 6 00:05:33 PDT 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

d-bugmail at puremagic.com schrieb am 2006-10-06:
> http://d.puremagic.com/issues/show_bug.cgi?id=402

> The following may be incorrect code, but it crashes the compiler.
>
>>dmd -c issue.d
> issue.d(8): mixin Foo!(y) cannot resolve forward reference
> ***** Crash *****
>
> ----- issue.d -----
> template Foo(alias b)
> {
>     int a() { return b; }
> }
>
> void main()
> {
>     mixin Foo!(y) y;
> }

Added to DStress as
http://dstress.kuehne.cn/nocompile/a/alias_39_A.d
http://dstress.kuehne.cn/nocompile/a/alias_39_B.d

Thomas


-----BEGIN PGP SIGNATURE-----

iD8DBQFFJgd8LK5blCcjpWoRAqsiAJ4k1BmBv/BEl95EbKk1Cp1uCvkKiACfX+Gy
5sr7FO3j1L4vAqhazLtL+Ik=
=/INU
-----END PGP SIGNATURE-----



More information about the Digitalmars-d-bugs mailing list