view gcc/testsuite/g++.dg/uninit-pred-4.C @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
line wrap: on
line source

/* { dg-do compile } */
/* { dg-options "-Wuninitialized -Og" } */

int pop ();
int pop_first_bucket;

int my_pop ()
{
  int out;  // { dg-bogus "uninitialized" "uninitialized variable warning" }

  while (pop_first_bucket)
    if (pop_first_bucket && (out = pop()))
      return out;

  return 0;
}