On Wed, Nov 01, 2000 at 02:21:27PM +0100, Andreas Beck wrote:
> > - giiPanic prototype is:
> >          void giiPanic(char *format, ...)

If you add __attribute__((noreturn)), GCC realizes that ggiPanic doesn't return
from ggiPanic and thus doesn't warn about code like the following:

int func(int a, int b)
{
  if(a==b) ggiPanic("a can't equal b\n");
  else     return 1;
}

Otherwise one has to do something like this:

  if(a==b) {
      ggiPanic("a can't equal b\n");
      return 0;  /* Can't be reached */
  }

-- 
                                           Niklas

Reply via email to