This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/25756] ICE on valid code with labels
- From: "kargl at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Jan 2006 20:18:47 -0000
- Subject: [Bug fortran/25756] ICE on valid code with labels
- References: <bug-25756-11811@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from kargl at gcc dot gnu dot org 2006-01-12 20:18 -------
The following simple patch
Index: parse.c
===================================================================
--- parse.c (revision 109606)
+++ parse.c (working copy)
@@ -349,8 +349,10 @@ next_free (void)
{
gfc_warning_now
("Ignoring statement label in empty statement at %C");
+#if 0
gfc_free_st_label (gfc_statement_label);
gfc_statement_label = NULL;
+#endif
return ST_NONE;
}
}
get rids of the ICE, but I don't understand why we have an ICE in first place.
The patch simply retains the labeled empty statement in the list of labels.
I haven't tested the patch beyond a simple program similar to those posted
by Bernhard.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25756