trans.c (gnat_to_gnu): Set gnu_result to NULL_TREE on entry.

* trans.c (gnat_to_gnu) <N_Return_Statement>: Set gnu_result
	to NULL_TREE on entry.

From-SVN: r96528
This commit is contained in:
Eric Botcazou 2005-03-15 19:21:36 +00:00 committed by Eric Botcazou
parent 3562bc34e8
commit 813edff1aa
2 changed files with 7 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2005-03-15 Eric Botcazou <ebotcazou@adacore.com>
* trans.c (gnat_to_gnu) <N_Return_Statement>: Set gnu_result
to NULL_TREE on entry.
2005-03-15 Robert Dewar <dewar@adacore.com>
* system-unixware.ads, system-linux-ia64.ads, system-freebsd-x86.ads,

View File

@ -3500,6 +3500,8 @@ gnat_to_gnu (Node_Id gnat_node)
tree gnu_ret_val = NULL_TREE;
/* The place to put the return value. */
tree gnu_lhs;
/* Avoid passing error_mark_node to RETURN_EXPR. */
gnu_result = NULL_TREE;
/* If we are dealing with a "return;" from an Ada procedure with
parameters passed by copy in copy out, we need to return a record