summaryrefslogtreecommitdiffstats
path: root/debian/uncrustify-trinity/uncrustify-trinity-0.78.0/tests/input/c/enum-struct-init.c
blob: 6660e4a4c970b1d92c928086fb21bb0c58277df4 (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
30
31

enum foo_idx
{
   FOO_1,
   FOO_2,
   FOO_3,
};

struct foo
{
   const char *str;
   int        values[8];
};

struct foo bar[] =
{
   [FOO_1] = {
      "junk",
      { 1 } },

   [FOO_2] = {
      "morejunk",
      {1, 2, 3} },

   [FOO_3] = {
      "somemore",
      {1, 2, 3, 4, 5, 6} },

};