c/10170: Is this a bug of GCC? or it's a C syntax

xkinh@yahoo.com xkinh@yahoo.com
Thu Mar 20 19:19:00 GMT 2003


>Number:         10170
>Category:       c
>Synopsis:       Is this a bug of GCC? or it's a C syntax
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Mar 20 18:26:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Kinh Nguyen
>Release:        3.2.2 and earlier
>Organization:
>Environment:
Linux, Sun
>Description:
compile the following program and run it.  Is it a GCC bug or
it's a c syntax? (I'm not sure but other compilers give
an error message).

#include <stdio.h>
int alwayzero();
main(){
  if (alwayzero) 
    printf("Is this a GCC bug or it's the C syntax\n");
}
int alwayzero() {return 0;}
>How-To-Repeat:
Try to compile and run the program.  Other compile will give error messages
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the Gcc-bugs mailing list