summaryrefslogtreecommitdiffstats
path: root/debian/uncrustify-trinity/uncrustify-trinity-0.75.0/tests/input/c/else-if.c
blob: 06cc37f2eb40992345a8b722be8a56505f07b2d9 (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
28
29
int test (int A, int B) {

  int C;

  if (A == 0)
    if (B == 0)
      C = 1;
    else if (B == 1)
      C = 2;
    else
      C = 3;
  else if (A == 1)
    if (B == 0)
      C = 4;
    else if (B == 1)
      C = 5;
    else
      C = 6;
  else
    if (B == 0)
      C = 7;
    else if (B == 1)
      C = 8;
    else
      C = 9;

  return C;
}