From 7ea6b6cf97363a0f4dfb1a72a7cda31c59350bbc Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Fri, 11 Jun 2010 14:29:53 +0200 Subject: invoke.texi (Wsuggest-attribute): Document. * doc/invoke.texi (Wsuggest-attribute): Document. (Wmissing-noreturn): Remove. * ipa-pure-const.c (warn_function_noreturn): New function. * opts.c (decode_options): Set warn_suggest_attribute_noreturn on warn_missing_noreturn. * common.opt (Wsuggest-attribute=noreturn): New. * tree-flow.h (warn_function_noreturn): Declare. * tree-cfg.c (execute_warn_function_noreturn): Use warn_function_noreturn. (gate_warn_function_noreturn): New. (pass_warn_function_noreturn): Update. From-SVN: r160606 --- gcc/opts.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gcc/opts.c') diff --git a/gcc/opts.c b/gcc/opts.c index 8699ec3..e304ce5 100644 --- a/gcc/opts.c +++ b/gcc/opts.c @@ -1062,6 +1062,11 @@ decode_options (unsigned int argc, const char **argv) "is disabled."); flag_toplevel_reorder = 0; } + + /* -Wmissing-noreturn is alias for -Wsuggest-attribute=noreturn. */ + if (warn_missing_noreturn) + warn_suggest_attribute_noreturn = true; + /* Unless the user has asked for section anchors, we disable toplevel reordering at -O0 to disable transformations that might be surprising to end users and to get -fno-toplevel-reorder tested. */ -- cgit v1.1