------- Additional Comments From steven at gcc dot gnu dot org 2005-01-20 09:10 ------- >From expr.c:count_type_elements: case UNION_TYPE: case QUAL_UNION_TYPE: { /* Ho hum. How in the world do we guess here? Clearly it isn't right to count the fields. Guess based on the number of words. */ HOST_WIDE_INT n = int_size_in_bytes (type); if (n < 0) return -1; return n / UNITS_PER_WORD; } So we cannot use count_type_elements in gimplify_init_constructor. I think we should somehow compute the size of the CONSTRUCTOR and compare it with int_size_in_bytes (TREE_TYPE (object))...?
-- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19515