https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71883
--- Comment #6 from paul.richard.thomas at gmail dot com <paul.richard.thomas at gmail dot com> --- Hi Steve, Thanks, you beat me to it! Cheers Paul PS Since I caused this regression, perhaps I should take it on :-) On 22 July 2016 at 16:45, kargl at gcc dot gnu.org <gcc-bugzi...@gcc.gnu.org> wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71883 > > --- Comment #5 from kargl at gcc dot gnu.org --- > (In reply to Thomas Koenig from comment #4) >> The problem here is that we want to do some dependency >> checking on something that is invalid. >> >> Maybe the best way would be to skip the whole pass if a >> previous fatal error was diagnosed. >> >> Is there a way to check for this? > > You can check the error count. If it is > greater than 0, you have an error. Here's > an example from my private tree > > --- expr.c (revision 237945) > +++ expr.c (working copy) > @@ -970,8 +970,14 @@ gfc_is_constant_expr (gfc_expr *e) > > > default: > - gfc_internal_error ("gfc_is_constant_expr(): Unknown expression type"); > - return 0; > + { > + int e, w; > + gfc_get_errors (&w, &e); > + if (e < 1) > + gfc_internal_error ("gfc_is_constant_expr(): Unknown " > + "expression type"); > + return 0; > + } > } > } > > -- > You are receiving this mail because: > You are on the CC list for the bug.