------- Comment #3 from pault at gcc dot gnu dot org 2008-06-07 09:05 ------- Index: gcc/fortran/resolve.c > =================================================================== > *** gcc/fortran/resolve.c (revision 136412) > --- gcc/fortran/resolve.c (working copy) > *************** resolve_fl_derived (gfc_symbol *sym) > *** 7637,7642 **** > --- 7637,7647 ---- > return FAILURE; > } > > + /* Ensure that all the derived type components are put on the > + derived type list; even in formal namespaces. */ > + if (c->ts.type == BT_DERIVED && c->ts.derived) > + resolve_fl_derived (c->ts.derived); > + > if (c->pointer || c->allocatable || c->as == NULL) > continue;
This patch broke some tests because it gets into a loop with pointer components whose type is the same as the 'host' derived type. This was easily fixed. I could not apply the patch because my tree update went pear-shaped. I'll fix it all in a weeks time, when I'm back home. Paul -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36366