http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45933
janus at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED AssignedTo|unassigned at gcc dot |janus at gcc dot gnu.org |gnu.org | --- Comment #2 from janus at gcc dot gnu.org 2010-10-07 13:55:02 UTC --- Mine. Here's a patch: Index: gcc/fortran/resolve.c =================================================================== --- gcc/fortran/resolve.c (revision 165052) +++ gcc/fortran/resolve.c (working copy) @@ -5719,13 +5719,12 @@ resolve_typebound_function (gfc_expr* e) /* Deal with typebound operators for CLASS objects. */ expr = e->value.compcall.base_object; - if (expr && expr->symtree->n.sym->ts.type == BT_CLASS - && e->value.compcall.name) + if (expr && expr->ts.type == BT_CLASS && e->value.compcall.name) { /* Since the typebound operators are generic, we have to ensure that any delays in resolution are corrected and that the vtab is present. */ - ts = expr->symtree->n.sym->ts; + ts = expr->ts; declared = ts.u.derived; c = gfc_find_component (declared, "$vptr", true, true); if (c->ts.u.derived == NULL)