[Issue 1922] New: struct literal segfaults for structs with nested union/struct

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Mar 13 11:10:28 PDT 2008


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

           Summary: struct literal segfaults for structs with nested
                    union/struct
           Product: DGCC aka GDC
           Version: 0.24
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: glue layer
        AssignedTo: dvdfrdmn at users.sf.net
        ReportedBy: baryluk at mpi.int.pl


module vec1;

struct vec1 {
        union {
                struct {
                        float x;
                }
                float cell;
        }

        vec1 opMul(float c) {
                return vec1(c*x); // line 12
        }
}

$ gdc -c vec1.d
vec1.d: In member function ‘opMul’:
vec1.d:12: internal compiler error: Naruszenie ochrony pamięci (Segmentation
fault)
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.


-- 



More information about the D.gnu mailing list