re PR target/27421 (ICE with invalid array in struct)
PR target/27421 * config/i386/i386.c (classify_argument): Skip fields with invalid types in unions. * gcc.dg/union-3.c: New test. From-SVN: r114494
This commit is contained in:
parent
524e3576e6
commit
118ed72a74
@ -1,3 +1,9 @@
|
||||
2006-06-08 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
|
||||
|
||||
PR target/27421
|
||||
* config/i386/i386.c (classify_argument): Skip fields with invalid
|
||||
types in unions.
|
||||
|
||||
2006-06-08 Steven Bosscher <steven@gcc.gnu.org>
|
||||
|
||||
* cse.c (flush_hash_table): Use VOIDmode to invalidate a REG.
|
||||
|
@ -3045,6 +3045,10 @@ classify_argument (enum machine_mode mode, tree type,
|
||||
if (TREE_CODE (field) == FIELD_DECL)
|
||||
{
|
||||
int num;
|
||||
|
||||
if (TREE_TYPE (field) == error_mark_node)
|
||||
continue;
|
||||
|
||||
num = classify_argument (TYPE_MODE (TREE_TYPE (field)),
|
||||
TREE_TYPE (field), subclasses,
|
||||
bit_offset);
|
||||
|
@ -1,3 +1,8 @@
|
||||
2006-06-08 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
|
||||
|
||||
PR target/27421
|
||||
* gcc.dg/union-3.c: New test.
|
||||
|
||||
2006-06-08 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR middle-end/27116
|
||||
|
10
gcc/testsuite/gcc.dg/union-3.c
Normal file
10
gcc/testsuite/gcc.dg/union-3.c
Normal file
@ -0,0 +1,10 @@
|
||||
/* PR target/27421 */
|
||||
/* { dg-do compile } */
|
||||
|
||||
union A
|
||||
{
|
||||
int i;
|
||||
void x[1]; /* { dg-error "array of voids" } */
|
||||
};
|
||||
|
||||
void foo(union A a) {}
|
Loading…
Reference in New Issue
Block a user