summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr28121.c
blob: 5cbf8f89e943773946c57a75a8c60ca684c32836 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/* { dg-do compile } */
/* { dg-options "-O2" } */

short
GetCmd ()
{
  int c, c1;
  for (c = 255; c == 255;)
    {
      c = GetMouseButton ();
      if (c >= 0)
	{
	  c = ParsePos (c, -1, 0);
	  c1 = ParsePos (c1, c, 1);
	  if (c == c1 && (c >= 0 || c == -10))
	    {
	      return c;
	    }
	  if (c >= 0 && c1 == -12)
	    {
	      return ((((((10) + 1) + 1)) + 1) << 7) | c;
	    }
	  c = 255;
	}
    }
}