diff --git a/gcc/calls.c b/gcc/calls.c index be3a498eb2f..9ad7d1665e0 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -562,7 +562,8 @@ expand_call (exp, target, ignore) Use abstraction instead of setting TREE_ADDRESSABLE directly. */ - if (DECL_INLINE (fndecl) && extra_warnings && !flag_no_inline) + if (DECL_INLINE (fndecl) && extra_warnings && warn_inline + && !flag_no_inline) warning_with_decl (fndecl, "can't inline call to `%s' which was declared inline"); mark_addressable (fndecl); } diff --git a/gcc/flags.h b/gcc/flags.h index e36a662d1b2..22bd1f04f81 100644 --- a/gcc/flags.h +++ b/gcc/flags.h @@ -73,6 +73,10 @@ extern int extra_warnings; extern int warn_unused; +/* Nonzero means warn if inline function is too large. */ + +extern int warn_inline; + /* Nonzero to warn about variables used before they are initialized. */ extern int warn_uninitialized;