On Tue, Sep 09, 2014 at 10:51:23PM +0000, Joseph S. Myers wrote:
> On Thu, 28 Aug 2014, Maxim Ostapenko wrote:
> 
> > diff --git a/gcc/diagnostic.c b/gcc/diagnostic.c
> > index 0cc7593..67b8c5b 100644
> > --- a/gcc/diagnostic.c
> > +++ b/gcc/diagnostic.c
> > @@ -492,7 +492,7 @@ diagnostic_action_after_output (diagnostic_context 
> > *context,
> >     real_abort ();
> >        diagnostic_finish (context);
> >        fnotice (stderr, "compilation terminated.\n");
> > -      exit (FATAL_EXIT_CODE);
> > +      exit (ICE_EXIT_CODE);
> 
> Why?  This is the case for fatal_error.  FATAL_EXIT_CODE seems right for 
> this, and ICE_EXIT_CODE wrong.

So that the driver can understand the difference between an ICE and other
fatal errors (e.g. sorry etc.).
Users are typically using the driver and for them it matters what exit code
is returned from the driver, not from cc1/cc1plus etc.

        Jakub

Reply via email to