From 8b6866afc342340bd8d8674caf6d773afe0de5f1 Mon Sep 17 00:00:00 2001 From: dj Date: Wed, 25 May 2005 03:59:00 +0000 Subject: * c-common.c (unsigned_conversion_warning): Move warning control from if() to warning(OPT_*). (c_common_truthvalue_conversion): Likewise. (c_do_switch_warnings): Likewise. * c-decl.c (diagnose_mismatched_decls): Likewise. (diagnose_mismatched_decls): Likewise. (define_label): Likewise. (grokdeclarator): Likewise. * c-format.c (check_format_info): Likewise. * c-lex.c (interpret_integer): Likwise. (lex_string): Likewise. * c-opts.c (c_common_post_options): Likewise. * c-parser.c (c_parser_unary_expression): Likewise. * c-pragma.c (handle_pragma_redefine_extname): Likewise. (handle_pragma_extern_prefix): Likewise. * c-typeck.c (build_binary_op): Likewise. * gcse.c (is_too_expensive): Likewise. * opts.c (decode_options): Likewise. * stor-layout.c (place_field): Likewise. * tree-cfg.c (remove_bb): Likewise. * c.opt (-Wreturn-type): Add Var(warn_return_type). * flags.h (warn_return_type): Remove. * toplev.c (warn_return_type): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@100135 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/c-parser.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'gcc/c-parser.c') diff --git a/gcc/c-parser.c b/gcc/c-parser.c index 96bab469f41..04fffd1a23f 100644 --- a/gcc/c-parser.c +++ b/gcc/c-parser.c @@ -4518,8 +4518,9 @@ c_parser_unary_expression (c_parser *parser) return ret; case CPP_PLUS: c_parser_consume_token (parser); - if (!c_dialect_objc () && warn_traditional && !in_system_header) - warning (0, "traditional C rejects the unary plus operator"); + if (!c_dialect_objc () && !in_system_header) + warning (OPT_Wtraditional, + "traditional C rejects the unary plus operator"); return parser_build_unary_op (CONVERT_EXPR, c_parser_cast_expression (parser, NULL)); case CPP_MINUS: -- cgit v1.2.1