diff options
author | Tobias Burnus <burnus@net-b.de> | 2011-08-25 17:59:40 +0200 |
---|---|---|
committer | Tobias Burnus <burnus@gcc.gnu.org> | 2011-08-25 17:59:40 +0200 |
commit | 241e79cfc4264dec4eaf1e8af890da3527c99193 (patch) | |
tree | 5fe429060de3f16e0acb93e0ee8d122619a38ffa /gcc/fortran/trans-expr.c | |
parent | 3e4c754bbf3709a6dcd41e672e5e90d5c582aaca (diff) | |
download | gcc-241e79cfc4264dec4eaf1e8af890da3527c99193.zip gcc-241e79cfc4264dec4eaf1e8af890da3527c99193.tar.gz gcc-241e79cfc4264dec4eaf1e8af890da3527c99193.tar.bz2 |
trans-array.c (structure_alloc_comps): Fix for allocatable scalar coarray components.
2011-08-25 Tobias Burnus <burnus@net-b.de>
* trans-array.c (structure_alloc_comps): Fix for allocatable
scalar coarray components.
* trans-expr.c (gfc_conv_component_ref): Ditto.
* trans-type.c (gfc_get_derived_type): Ditto.
2011-08-25 Tobias Burnus <burnus@net-b.de>
* gfortran.dg/coarray/alloc_comp_1.f90: New.
From-SVN: r178068
Diffstat (limited to 'gcc/fortran/trans-expr.c')
-rw-r--r-- | gcc/fortran/trans-expr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/fortran/trans-expr.c b/gcc/fortran/trans-expr.c index 39a83ce..531a135 100644 --- a/gcc/fortran/trans-expr.c +++ b/gcc/fortran/trans-expr.c @@ -564,7 +564,8 @@ gfc_conv_component_ref (gfc_se * se, gfc_ref * ref) se->string_length = tmp; } - if (((c->attr.pointer || c->attr.allocatable) && c->attr.dimension == 0 + if (((c->attr.pointer || c->attr.allocatable) + && (!c->attr.dimension && !c->attr.codimension) && c->ts.type != BT_CHARACTER) || c->attr.proc_pointer) se->expr = build_fold_indirect_ref_loc (input_location, |