http://d.puremagic.com/issues/show_bug.cgi?id=7058
Summary: static initializer for structs doesn't respect init values of members Product: D Version: D1 & D2 Platform: All OS/Version: All Status: NEW Keywords: wrong-code Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: mrmoc...@gmx.de --- Comment #0 from Trass3r <mrmoc...@gmx.de> 2011-12-02 18:50:33 PST --- void main() { import std.stdio; vec3 v = {1.5f, 2}; // with vec3(1.5f, 2) z becomes 0 writeln(v); } struct vec3 { // union // { // struct // { float x = 0; float y = 0; float z = 0; // } // float[3] cell; // } } $ dmd -run vector.d vec3(1.5, 2, nan) -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------