diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1993-12-03 07:06:46 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1993-12-03 07:06:46 -0500 |
commit | 70768eda2a70f2e637d3422b5479b6f7b6eeb27f (patch) | |
tree | 1611603953f895cd11fa9b43d0bfdccc75df8216 | |
parent | ec044cecc2cda3b821f2cd91ad4167a127cf575c (diff) | |
download | gcc-70768eda2a70f2e637d3422b5479b6f7b6eeb27f.zip gcc-70768eda2a70f2e637d3422b5479b6f7b6eeb27f.tar.gz gcc-70768eda2a70f2e637d3422b5479b6f7b6eeb27f.tar.bz2 |
(c_expand_return): Return if convert_for_assignment returns
error_mark_node.
From-SVN: r6185
-rw-r--r-- | gcc/c-typeck.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c index 15428e4..ed5fcdc 100644 --- a/gcc/c-typeck.c +++ b/gcc/c-typeck.c @@ -6155,6 +6155,10 @@ c_expand_return (retval) tree t = convert_for_assignment (valtype, retval, "return", NULL_TREE, NULL_TREE, 0); tree res = DECL_RESULT (current_function_decl); + + if (t == error_mark_node) + return; + t = build (MODIFY_EXPR, TREE_TYPE (res), res, convert (TREE_TYPE (res), t)); TREE_SIDE_EFFECTS (t) = 1; |