[Issue 3884] New: Segfault: typedef present when passing array in tuple argument to function template

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Mar 6 00:54:57 PST 2010


http://d.puremagic.com/issues/show_bug.cgi?id=3884

           Summary: Segfault: typedef present when passing array in tuple
                    argument to function template
           Product: D
           Version: 1.056
          Platform: x86_64
        OS/Version: Linux
            Status: NEW
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: matti.niemenmaa+dbugzilla at iki.fi


--- Comment #0 from Matti Niemenmaa <matti.niemenmaa+dbugzilla at iki.fi> 2010-03-06 00:54:56 PST ---
The following code causes DMD 1.056 to segfault:


typedef int X;
X[] a;

void f() { g(a); }

void g(T...)(T x) {}


Using int[] instead of X[] works.

However, interestingly enough, keeping the typedef but using an int[] also
causes a segfault, even though the typedef is unused:


typedef int X;
int[] a;

void f() { g(a); }

void g(T...)(T x) {}

-- 
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