diff options
author | Paul Thomas <pault@gcc.gnu.org> | 2018-09-17 07:18:17 +0000 |
---|---|---|
committer | Paul Thomas <pault@gcc.gnu.org> | 2018-09-17 07:18:17 +0000 |
commit | ca32d61bab85b4df400d463ff891e4f833bad8ec (patch) | |
tree | 73ac3b0468f763ffe46fc2d04f7ca235be6b1f36 /gcc/fortran/trans-array.c | |
parent | 3cc2fdfd93efaf1b2e8bcffe84c20cbd1ffc4e96 (diff) | |
download | gcc-ca32d61bab85b4df400d463ff891e4f833bad8ec.zip gcc-ca32d61bab85b4df400d463ff891e4f833bad8ec.tar.gz gcc-ca32d61bab85b4df400d463ff891e4f833bad8ec.tar.bz2 |
re PR fortran/85954 (ICE in make_ssa_name_fn, at tree-ssanames.c:266)
2018-09-17 Paul Thomas <pault@gcc.gnu.org>
PR fortran/85954
* resolve.c (resolve_assoc_var): If the target expression is a
deferred charlen dummy and the associate name shares the
charlen, generate a new one. Make sure that new charlens are in
the namespace list so that they get cleaned up.
* trans-array.c (gfc_is_reallocatable_lhs): Associate names are
not reallocatable.
* trans-decl.c (gfc_get_symbol_decl): Put deferred character
length dummy and result arrays on the deferred initialization
list so that the variable length arrays can be correctly dealt
with.
* trans-expr.c (gfc_conv_string_length): Return if 'expr' is
NULL rather than ICEing..
2018-09-17 Paul Thomas <pault@gcc.gnu.org>
PR fortran/85954
* gfortran.dg/deferred_character_21.f90 : New test.
From-SVN: r264358
Diffstat (limited to 'gcc/fortran/trans-array.c')
-rw-r--r-- | gcc/fortran/trans-array.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/fortran/trans-array.c b/gcc/fortran/trans-array.c index 473bfc5..9565b7d 100644 --- a/gcc/fortran/trans-array.c +++ b/gcc/fortran/trans-array.c @@ -9520,6 +9520,9 @@ gfc_is_reallocatable_lhs (gfc_expr *expr) sym = expr->symtree->n.sym; + if (sym->attr.associate_var) + return false; + /* An allocatable class variable with no reference. */ if (sym->ts.type == BT_CLASS && CLASS_DATA (sym)->attr.allocatable |