aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.dg/setjmp-5.c
blob: c6e5f931746115f78be193d7e212623c4eaef5e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* { dg-do compile } */
/* { dg-options "-O2 -Wall" } */

#include <setjmp.h>

void bar (int);

jmp_buf buf;
int v;

void
foo (void)
{
  int i;
  bar (0);
  bar (1);
  i = 5;
  int j = setjmp (buf);
  if (j == 0)
    bar (2);
  v = i;	/* { dg-bogus "may be used uninitialized in this function" } */
}