2016-05-06 Richard Biener <rguenther@suse.de>
PR middle-end/70931
* dwarf2out.c (native_encode_initializer): Skip zero-sized fields.
* gfortran.dg/pr70931.f90: New testcase.
From-SVN: r235944
+2016-05-06 Richard Biener <rguenther@suse.de>
+
+ PR middle-end/70931
+ * dwarf2out.c (native_encode_initializer): Skip zero-sized fields.
+
2016-05-06 Richard Biener <rguenther@suse.de>
PR middle-end/70941
fieldsize = tree_to_shwi (DECL_SIZE_UNIT (field));
pos = int_byte_position (field);
gcc_assert (pos + fieldsize <= size);
- if (val
+ if (val && fieldsize != 0
&& !native_encode_initializer (val, array + pos, fieldsize))
return false;
}
+2016-05-06 Richard Biener <rguenther@suse.de>
+
+ PR middle-end/70931
+ * gfortran.dg/pr70931.f90: New testcase.
+
2016-05-06 Richard Biener <rguenther@suse.de>
PR middle-end/70941
--- /dev/null
+! { dg-do compile }
+! { dg-options "-g" }
+program p
+ type t
+ integer :: a
+ integer :: b(0)
+ end type
+ type(t), parameter :: z = t(1, [2])
+ print *, z
+end