diff options
author | Ian Lance Taylor <iant@google.com> | 2009-05-29 22:45:54 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2009-05-29 22:45:54 +0000 |
commit | 72b5577d91948132078d1021b7db49f85bb884e4 (patch) | |
tree | 86965b7acc5db54a702c131ce74a286eef70f176 /gcc/calls.c | |
parent | b0999b01149d3b429c78b98a7c24dd6f9652c08c (diff) | |
download | gcc-72b5577d91948132078d1021b7db49f85bb884e4.zip gcc-72b5577d91948132078d1021b7db49f85bb884e4.tar.gz gcc-72b5577d91948132078d1021b7db49f85bb884e4.tar.bz2 |
builtins.c (validate_gimple_arglist): Don't use va_arg with enum type.
./: * builtins.c (validate_gimple_arglist): Don't use va_arg with
enum type.
* calls.c (emit_library_call_value_1): Likewise.
* c-typeck.c (c_build_va_arg): New function.
* c-tree.h (c_build_va_arg): Declare.
* c-parser.c (c_parser_postfix_expression): Call c_build_va_arg
instead of build_va_arg.
cp/:
* error.c (cp_printer): Don't use va_arg with enum type.
testsuite/:
* gcc.dg/Wcxx-compat-11.c: New testcase.
From-SVN: r147989
Diffstat (limited to 'gcc/calls.c')
-rw-r--r-- | gcc/calls.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/calls.c b/gcc/calls.c index 219b1d3..c10b0cd 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -3445,7 +3445,7 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value, for (; count < nargs; count++) { rtx val = va_arg (p, rtx); - enum machine_mode mode = va_arg (p, enum machine_mode); + enum machine_mode mode = (enum machine_mode) va_arg (p, int); /* We cannot convert the arg value to the mode the library wants here; must do it earlier where we know the signedness of the arg. */ |