[Issue 1400] New: static array in struct as parameter BROKEN

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Aug 4 10:58:09 PDT 2007


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

           Summary: static array in struct as parameter BROKEN
           Product: DGCC aka GDC
           Version: 0.23
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: critical
          Priority: P2
         Component: glue layer
        AssignedTo: dvdfrdmn at users.sf.net
        ReportedBy: default_357-line at yahoo.de


gentoo-pc ~/d $ cat bug2.d && gdc bug2.d -o bug2 && echo "----" && ./bug2
import std.stdio;
void test(float[3] t) { writefln("t is ", t); }
struct E { float[3] data; }
void main() { E[] es; E e; e.data[]=[5f, 6f, 7f]; es~=e; foreach (ref v; es)
test(v.data); }
----
t is [-2.36481e-05,-2.36481e-05,-1.75314]

I trust it is clear how completely and utterly fucked this output is.
 --downs


-- 



More information about the D.gnu mailing list