Commit baf05df0 by Mark Mitchell Committed by Mark Mitchell

* method.c (emit_thunk): Don't try to return a `void' value.

From-SVN: r33554
parent 04dfcc8f
2000-04-30 Mark Mitchell <mark@codesourcery.com>
* method.c (emit_thunk): Don't try to return a `void' value.
* optimize.c (initialize_inlined_parameters): If the parameter is
addressable, we need to make a new VAR_DECL, even if the
initializer is constant.
......
......@@ -2187,7 +2187,10 @@ emit_thunk (thunk_fndecl)
t = tree_cons (NULL_TREE, a, t);
t = nreverse (t);
t = build_call (function, t);
finish_return_stmt (t);
if (!same_type_p (TREE_TYPE (t), void_type_node))
finish_return_stmt (t);
else
finish_expr_stmt (t);
/* The back-end expects DECL_INITIAL to contain a BLOCK, so we
clear this here. */
......
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