This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/36366] [4.3/4.4 Regression] ICE in gfc_conv_component_ref
- From: "pault at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Jun 2008 09:05:49 -0000
- Subject: [Bug fortran/36366] [4.3/4.4 Regression] ICE in gfc_conv_component_ref
- References: <bug-36366-87@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- 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