re PR c/5615 (ICE in size_binop, at fold-const.c:1914)

PR c/5615
        * expr.h (ARGS_SIZE_TREE): Convert size.var to ssizetype.

From-SVN: r49904
This commit is contained in:
Richard Henderson 2002-02-20 10:34:28 -08:00 committed by Richard Henderson
parent d94084f79a
commit f322b42319
3 changed files with 9 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2002-02-20 Richard Henderson <rth@redhat.com>
PR c/5615
* expr.h (ARGS_SIZE_TREE): Convert size.var to ssizetype.
2002-02-20 Tom Tromey <tromey@redhat.com>
* config/fr30/fr30.h (DWARF_LINE_MIN_INSTR_LENGTH): Removed.

View File

@ -97,7 +97,8 @@ struct args_size
of type ssizetype. */
#define ARGS_SIZE_TREE(SIZE) \
((SIZE).var == 0 ? ssize_int ((SIZE).constant) \
: size_binop (PLUS_EXPR, (SIZE).var, ssize_int ((SIZE).constant)))
: size_binop (PLUS_EXPR, convert (ssizetype, (SIZE).var), \
ssize_int ((SIZE).constant)))
/* Convert the implicit sum in a `struct args_size' into an rtx. */
#define ARGS_SIZE_RTX(SIZE) \

View File

@ -0,0 +1,2 @@
/* PR c/5615 */
void f(int a, struct {int b[a];} c) {}