c++/10538: gcc 3.2.3 does not issue a warning for "int a = a + 1" statements

invi@your.toilet.ch invi@your.toilet.ch
Tue Apr 29 14:13:00 GMT 2003


>Number:         10538
>Category:       c++
>Synopsis:       gcc 3.2.3 does not issue a warning for "int a = a + 1" statements
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          accepts-illegal
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 29 14:06:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Remo Inverardi
>Release:        gcc-3.2.3
>Organization:
>Environment:
Debian SID
>Description:
The following code compiles without any warnings:

void foo()
{
  int xxx = xxx + 1;
}

I think some warning like "xxx was accessed without being initialized" would be appropriate.
>How-To-Repeat:
See description.
>Fix:

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



More information about the Gcc-bugs mailing list