aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.7/libmudflap/testsuite/libmudflap.c/pass32-frag.c
blob: d7f223279761cdd68d598c2b0f56daf7fd3f4a3d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

struct foo { char z[10]; };

char * get_z (struct foo *this)
{
  return & this->z[0] /* the `this' pointer is not dereferenced! */;
}

int main ()
{
struct foo k;
char *n = get_z (& k);
srand ((int)(__mf_uintptr_t) n); /* use the pointer value */
return 0;
}