calls.c (expand_call): Check warn_inline before complaining about not being able to inline a fn...

* calls.c (expand_call): Check warn_inline before complaining about
        not being able to inline a fn declared inline.
        * flags.h (warn_inline): Add extern decl.

From-SVN: r4171
This commit is contained in:
Brendan Kehoe 1993-04-16 21:42:17 -04:00
parent 818913ead2
commit 67729b992a
2 changed files with 6 additions and 1 deletions

View File

@ -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);
}

View File

@ -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;