This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/15181] gfc_conv_component_ref: Assertion `c->backend_decl' failed
- From: "olchansk at panix dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Jul 2004 02:30:51 -0000
- Subject: [Bug fortran/15181] gfc_conv_component_ref: Assertion `c->backend_decl' failed
- References: <20040427221144.15181.olchansk@panix.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From olchansk at panix dot com 2004-07-12 02:30 -------
This change seems to fix the ICE. In my example, gfc_typenode_for_spec() is
never called for "type(wire_type)", so I call to be hand.
[olchansk@send fortran]$ cvs diff -u trans-expr.c
Index: trans-expr.c
===================================================================
RCS file: /cvsroot/gcc/gcc/gcc/fortran/trans-expr.c,v
retrieving revision 1.12
diff -u -r1.12 trans-expr.c
--- trans-expr.c 29 Jun 2004 22:01:35 -0000 1.12
+++ trans-expr.c 12 Jul 2004 02:28:13 -0000
@@ -217,7 +217,9 @@
c = ref->u.c.component;
- assert (c->backend_decl);
+ gfc_typenode_for_spec(&c->ts);
+
+ assert(c->backend_decl);
field = c->backend_decl;
assert (TREE_CODE (field) == FIELD_DECL);
K.O.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15181