Niklas H�glund wrote:
>
> 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 */
> }
...which I would suggest for portability's sake.
Regards, Stefan
_______________________________________________________
Stefan Seefeld
Departement de Physique
Universite de Montreal
email: [EMAIL PROTECTED]
_______________________________________________________
...ich hab' noch einen Koffer in Berlin...