From 28ec36ea31db0ed21b4e076fb82f45d15feabfd5 Mon Sep 17 00:00:00 2001 From: Francois-Xavier Coudert Date: Wed, 10 Oct 2007 13:38:38 +0000 Subject: re PR fortran/33636 (Rejects valid use of vector subscript in derived type parameter) PR fortran/33636 * expr.c (find_array_section): Check for constructor constantness. From-SVN: r129208 --- gcc/fortran/expr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/fortran/expr.c') diff --git a/gcc/fortran/expr.c b/gcc/fortran/expr.c index 151b465..16dc2b1 100644 --- a/gcc/fortran/expr.c +++ b/gcc/fortran/expr.c @@ -1165,7 +1165,7 @@ find_array_section (gfc_expr *expr, gfc_ref *ref) { gcc_assert (begin); - if (begin->expr_type != EXPR_ARRAY) + if (begin->expr_type != EXPR_ARRAY || !gfc_is_constant_expr (begin)) { t = FAILURE; goto cleanup; -- cgit v1.1