Commit a4850ce9 by Jan Hubicka Committed by Jan Hubicka

re PR c/67106 (ICE: verify_type failed: type variant differs by TYPE_PACKED.…

re PR c/67106 (ICE: verify_type failed:  type variant differs by TYPE_PACKED. with -g -fpack-struct)


	PR c/67106
	* gcc.c-torture/compile/pr67106.c: New testcase.
	* c-decl.c: Set TYPE_PACKED in variants.

From-SVN: r231049
parent 75c8aac3
2015-11-29 Jan Hubicka <hubicka@ucw.cz>
PR c/67106
* c-decl.c: Set TYPE_PACKED in variants.
2015-11-27 Martin Liska <mliska@suse.cz>
PR c++/68312
......
......@@ -7213,7 +7213,8 @@ start_struct (location_t loc, enum tree_code code, tree name,
}
C_TYPE_BEING_DEFINED (ref) = 1;
TYPE_PACKED (ref) = flag_pack_struct;
for (tree v = TYPE_MAIN_VARIANT (ref); v; v = TYPE_NEXT_VARIANT (v))
TYPE_PACKED (v) = flag_pack_struct;
*enclosing_struct_parse_info = struct_parse_info;
struct_parse_info = XNEW (struct c_struct_parse_info);
......
2015-11-29 Jan Hubicka <hubicka@ucw.cz>
PR c/67106
* gcc.c-torture/compile/pr67106.c: New testcase.
2015-11-29 Jan Hubicka <hubicka@ucw.cz>
PR c/67581
* g++.dg/torture/pr67581.C: New testcase.
......
/* { dg-options "-g -fpack-struct" } */
typedef struct S S;
struct S
{
struct
{
S *s;
};
int a;
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment