summaryrefslogtreecommitdiff
path: root/test/regression/struct6.c
blob: d8d9cc9389b2a1a20473887fa73c7977b7abf84d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <stdio.h>

struct value {
  int tag;
  union {
    int i;
    double r;
    char * sl;
  } u;
};

void print_value(struct value * s)
{
  printf ("%d\n", s->u.i);
}