aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/decl.c
diff options
context:
space:
mode:
authorTobias Burnus <burnus@net-b.de>2010-03-17 10:53:40 +0100
committerTobias Burnus <burnus@gcc.gnu.org>2010-03-17 10:53:40 +0100
commitb3aefde2131ab8147d9cad974b24798b1b0a5d91 (patch)
tree978b2f56225a8d013d78445f9deae7c75e80ae5a /gcc/fortran/decl.c
parente33c42db5d391a77a9178f3d150153ebc50229a8 (diff)
downloadgcc-b3aefde2131ab8147d9cad974b24798b1b0a5d91.zip
gcc-b3aefde2131ab8147d9cad974b24798b1b0a5d91.tar.gz
gcc-b3aefde2131ab8147d9cad974b24798b1b0a5d91.tar.bz2
re PR fortran/43331 (Cray pointers generate bogus IL for the middle-end)
2010-03-17 Tobias Burnus <burnus@net-b.de> PR fortran/43331 * trans-array.c (gfc_conv_array_index_offset,gfc_conv_array_ref, gfc_conv_ss_startstride): Remove no-longer-needed cp_was_assumed check. * decl.c (gfc_match_derived_decl): Don't mark assumed-size Cray pointees as having explizit size. * expr.c (gfc_check_assign): Remove now unreachable Cray pointee check. * trans-types.c (gfc_is_nodesc_array): Add cp_was_assumed to * assert. (gfc_sym_type): Don't mark Cray pointees as restricted pointers. * resolve.c (resolve_symbol): Handle cp_was_assumed. * trans-decl.c (gfc_trans_deferred_vars): Ditto. (gfc_finish_var_decl): Don't mark Cray pointees as restricted pointers. 2010-03-17 Tobias Burnus <burnus@net-b.de> PR fortran/43331 * gfortran.dg/cray_pointers_1.f90: Update dg-error message. From-SVN: r157512
Diffstat (limited to 'gcc/fortran/decl.c')
-rw-r--r--gcc/fortran/decl.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/gcc/fortran/decl.c b/gcc/fortran/decl.c
index 0466906..692078a 100644
--- a/gcc/fortran/decl.c
+++ b/gcc/fortran/decl.c
@@ -6969,22 +6969,14 @@ gfc_match_derived_decl (void)
/* Cray Pointees can be declared as:
- pointer (ipt, a (n,m,...,*))
- By default, this is treated as an AS_ASSUMED_SIZE array. We'll
- cheat and set a constant bound of 1 for the last dimension, if this
- is the case. Since there is no bounds-checking for Cray Pointees,
- this will be okay. */
+ pointer (ipt, a (n,m,...,*)) */
match
gfc_mod_pointee_as (gfc_array_spec *as)
{
as->cray_pointee = true; /* This will be useful to know later. */
if (as->type == AS_ASSUMED_SIZE)
- {
- as->type = AS_EXPLICIT;
- as->upper[as->rank - 1] = gfc_int_expr (1);
- as->cp_was_assumed = true;
- }
+ as->cp_was_assumed = true;
else if (as->type == AS_ASSUMED_SHAPE)
{
gfc_error ("Cray Pointee at %C cannot be assumed shape array");