aboutsummaryrefslogtreecommitdiff
path: root/lldb/test/API/commands/expression/anonymous-struct/main.cpp
blob: d6366e7871523dbec20673bb6da5193b6ecf2da6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
typedef struct {
  float f;
  int i;
} my_untagged_struct;

double multiply(my_untagged_struct *s) { return s->f * s->i; }

double multiply(my_untagged_struct *s, int x) { return multiply(s) * x; }

int main(int argc, char **argv) {
  my_untagged_struct s = {
      .f = (float)argc,
      .i = argc,
  };
  // break here
  return multiply(&s, argc) > 0;
}