Commit 4bfc4dda by Jason Merrill Committed by Jason Merrill

typeck.c (build_function_call_real): Remove "inline called before definition" pedwarn.

	* typeck.c (build_function_call_real): Remove "inline called before
	definition" pedwarn.

	* pt.c (coerce_template_parms): Use maybe_fold_nontype_arg.

From-SVN: r17109
parent 4f69985c
Mon Dec 15 12:22:04 1997 Jason Merrill <jason@yorick.cygnus.com>
* typeck.c (build_function_call_real): Remove "inline called before
definition" pedwarn.
* pt.c (coerce_template_parms): Use maybe_fold_nontype_arg.
Sun Dec 14 22:34:20 1997 Jason Merrill <jason@yorick.cygnus.com> Sun Dec 14 22:34:20 1997 Jason Merrill <jason@yorick.cygnus.com>
* cvt.c (cp_convert_to_pointer): Fix base conversion of pm's. * cvt.c (cp_convert_to_pointer): Fix base conversion of pm's.
......
...@@ -1075,9 +1075,8 @@ coerce_template_parms (parms, arglist, in_decl) ...@@ -1075,9 +1075,8 @@ coerce_template_parms (parms, arglist, in_decl)
{ {
tree t = tsubst (TREE_TYPE (parm), vec, tree t = tsubst (TREE_TYPE (parm), vec,
TREE_VEC_LENGTH (vec), in_decl); TREE_VEC_LENGTH (vec), in_decl);
if (processing_template_decl && if (processing_template_decl)
(uses_template_parms (arg) || uses_template_parms (t))) val = maybe_fold_nontype_arg (arg);
val = arg;
else else
val = digest_init (t, arg, (tree *) 0); val = digest_init (t, arg, (tree *) 0);
......
...@@ -2645,12 +2645,6 @@ build_function_call_real (function, params, require_complete, flags) ...@@ -2645,12 +2645,6 @@ build_function_call_real (function, params, require_complete, flags)
pedwarn ("ANSI C++ forbids calling `main' from within program"); pedwarn ("ANSI C++ forbids calling `main' from within program");
} }
if (pedantic && DECL_THIS_INLINE (function) && ! DECL_INITIAL (function)
&& ! DECL_ARTIFICIAL (function)
&& ! DECL_PENDING_INLINE_INFO (function))
cp_pedwarn ("inline function `%#D' called before definition",
function);
/* Differs from default_conversion by not setting TREE_ADDRESSABLE /* Differs from default_conversion by not setting TREE_ADDRESSABLE
(because calling an inline function does not mean the function (because calling an inline function does not mean the function
needs to be separately compiled). */ needs to be separately compiled). */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment