www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 484] New: Compiler segfault with template variadic used as a template alias.

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=484

           Summary: Compiler segfault with template variadic used as a
                    template alias.
           Product: D
           Version: 0.173
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: minor
          Priority: P5
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: clugdbug yahoo.com.au


I'm not sure what this should do, actually -- but it shouldn't crash.
--------
template g(alias B)
{
    int g = 2;
}

int f(A...)(A a)
{
    return g!(a);
}

int main()
{
    return f(4);
}


-- 
Nov 06 2006
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=484


deewiant gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED





Fixed in DMD 0.174.


-- 
Nov 15 2006
prev sibling parent Thomas Kuehne <thomas-dloop kuehne.cn> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

d-bugmail puremagic.com schrieb am 2006-11-06:
 http://d.puremagic.com/issues/show_bug.cgi?id=484
 I'm not sure what this should do, actually -- but it shouldn't crash.
 --------
 template g(alias B)
 {
     int g = 2;
 }

 int f(A...)(A a)
 {
     return g!(a);
 }

 int main()
 {
     return f(4);
 }
Added to DStress as http://dstress.kuehne.cn/run/t/tuple_02_A.d Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFFZYWiLK5blCcjpWoRAhHQAJ9QB1y8yR/x7DAmpD0jd+d8SXKysQCgh7ac ZpcVLkU5L7wnVmlTJou495M= =2Cyw -----END PGP SIGNATURE-----
Nov 23 2006