diff options
author | Paul Thomas <pault@gcc.gnu.org> | 2018-09-11 15:59:07 +0000 |
---|---|---|
committer | Paul Thomas <pault@gcc.gnu.org> | 2018-09-11 15:59:07 +0000 |
commit | 3b949026d4ceb442a3cd43a429b36c800970a2d6 (patch) | |
tree | 8a737b03c80de2c8d93933de4496f1802a084c29 /gcc/fortran/expr.c | |
parent | b34e743c9c7a530c102c0c6bb1737ff2a0528da0 (diff) | |
download | gcc-3b949026d4ceb442a3cd43a429b36c800970a2d6.zip gcc-3b949026d4ceb442a3cd43a429b36c800970a2d6.tar.gz gcc-3b949026d4ceb442a3cd43a429b36c800970a2d6.tar.bz2 |
re PR fortran/87277 (Segfault on using array component of class scalar pointer as an actual argument)
2018-09-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/87277
* expr.c (is_subref_array): Add the check of dimensionality for
class, dummy, pointer arrays.
2018-09-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/87277
* gfortran.dg/select_type_43.f90: New test.
From-SVN: r264210
Diffstat (limited to 'gcc/fortran/expr.c')
-rw-r--r-- | gcc/fortran/expr.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/fortran/expr.c b/gcc/fortran/expr.c index 97792fe..3315bb8 100644 --- a/gcc/fortran/expr.c +++ b/gcc/fortran/expr.c @@ -1069,6 +1069,7 @@ is_subref_array (gfc_expr * e) if (e->symtree->n.sym->ts.type == BT_CLASS && e->symtree->n.sym->attr.dummy + && CLASS_DATA (e->symtree->n.sym)->attr.dimension && CLASS_DATA (e->symtree->n.sym)->attr.class_pointer) return true; |