http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56972



             Bug #: 56972

           Summary: Missing "may be used uninitialized" warning for

                    "obvious" uninitialized

    Classification: Unclassified

           Product: gcc

           Version: unknown

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: c

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: ppluzhni...@google.com





Google ref: b/8616613



// t.c

int f(int x)

{

  int ret;

  switch (x) {

    case 3:

      ret = 0;

      break;

  }

  return ret;

}



int main()

{

  return f(2);

}



gcc -c -Wall -Wextra t.c

# no output



gcc -c -Wall -Wextra -O2 t.c

# no output

Reply via email to