aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/expr.c
diff options
context:
space:
mode:
authorTobias Burnus <burnus@net-b.de>2012-01-16 20:50:11 +0100
committerTobias Burnus <burnus@gcc.gnu.org>2012-01-16 20:50:11 +0100
commit22c30bc09a6ff27638521bd82ac5e25c525f1273 (patch)
tree2dcdb80d1e52c4767c27a1030fe645cf115655e9 /gcc/fortran/expr.c
parent645c7a55f8861f10f68f3e7fc2ce86fa57fb6b15 (diff)
downloadgcc-22c30bc09a6ff27638521bd82ac5e25c525f1273.zip
gcc-22c30bc09a6ff27638521bd82ac5e25c525f1273.tar.gz
gcc-22c30bc09a6ff27638521bd82ac5e25c525f1273.tar.bz2
re PR fortran/51809 ([OOP] ICE (segfault) depending on USE statements order)
2012-01-16 Tobias Burnus <burnus@net-b.de> PR fortran/51809 * class.c (gfc_find_derived_vtab): Mark __vtab and __def_init as FL_VARIABLE not as FL_PARAMETER. * expr.c (gfc_simplify_expr): Remove special handling of __vtab. * resolve.c (resolve_values): Ditto. * trans-decl.c (gfc_get_symbol_decl): Mark __vtab and __def_init as TREE_READONLY. 2012-01-16 Tobias Burnus <burnus@net-b.de> PR fortran/51809 * gfortran.dg/use_20.f90: New From-SVN: r183219
Diffstat (limited to 'gcc/fortran/expr.c')
-rw-r--r--gcc/fortran/expr.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/fortran/expr.c b/gcc/fortran/expr.c
index a6baa68..8f04c73 100644
--- a/gcc/fortran/expr.c
+++ b/gcc/fortran/expr.c
@@ -1883,8 +1883,7 @@ gfc_simplify_expr (gfc_expr *p, int type)
initialization expression, or we want a subsection. */
if (p->symtree->n.sym->attr.flavor == FL_PARAMETER
&& (gfc_init_expr_flag || p->ref
- || p->symtree->n.sym->value->expr_type != EXPR_ARRAY)
- && !p->symtree->n.sym->attr.vtab)
+ || p->symtree->n.sym->value->expr_type != EXPR_ARRAY))
{
if (simplify_parameter_variable (p, type) == FAILURE)
return FAILURE;