summaryrefslogtreecommitdiff
path: root/gcc/fortran/expr.c
diff options
context:
space:
mode:
authorjanus <janus@138bc75d-0d04-0410-961f-82ee72b054a4>2016-12-02 18:38:24 +0000
committerjanus <janus@138bc75d-0d04-0410-961f-82ee72b054a4>2016-12-02 18:38:24 +0000
commit5b40964e2e9312482d6c5a3f8a166cc55584604c (patch)
tree9945c482626c336e1259469d20d9f43ff38cf904 /gcc/fortran/expr.c
parent699ca358e47eea2ae3801c7d5577efc4459d0698 (diff)
2016-12-02 Janus Weil <janus@gcc.gnu.org>
Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/78618 * check.c (gfc_check_rank): Remove ATTRIBUTE_UNUSED. * expr.c (gfc_check_assign): Fix error propagation. 2016-12-02 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/78618 * gfortran.dg/char_conversion.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243201 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/fortran/expr.c')
-rw-r--r--gcc/fortran/expr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/fortran/expr.c b/gcc/fortran/expr.c
index 60f6080877f4..c01418d48401 100644
--- a/gcc/fortran/expr.c
+++ b/gcc/fortran/expr.c
@@ -3314,9 +3314,9 @@ gfc_check_assign (gfc_expr *lvalue, gfc_expr *rvalue, int conform,
if (lvalue->ts.type == BT_CHARACTER && rvalue->ts.type == BT_CHARACTER)
{
if (lvalue->ts.kind != rvalue->ts.kind && allow_convert)
- gfc_convert_chartype (rvalue, &lvalue->ts);
-
- return true;
+ return gfc_convert_chartype (rvalue, &lvalue->ts);
+ else
+ return true;
}
if (!allow_convert)