1/* 2 * Copyright 2014, NICTA 3 * 4 * This software may be distributed and modified according to the terms of 5 * the BSD 2-Clause license. Note that NO WARRANTY is provided. 6 * See "LICENSE_BSD2.txt" for details. 7 * 8 * @TAG(NICTA_BSD) 9 */ 10 11int x, y; 12char c; 13 14 15int *f (int *array) 16{ 17 return &array[10]; 18} 19 20int a[10]; 21int a2[10]; 22int b1[10][10]; 23int b2[10][10]; 24int ca[10]; 25int d[10][10]; 26 27struct s { 28 int arrayfld[10]; 29 int data; 30}; 31 32struct s s1, s2; 33 34int *f2(void) 35{ 36 int y = *f(&b1[5][4]); 37 int z = *f(b2[3]); 38 int q = *f(s1.arrayfld); 39 int q2 = *f((int *)a); 40 return f(&a[6] + y + z + ca[5] + d[3][2] + q + s2.arrayfld[3] + *a2); 41} 42 43int *g(int c) 44{ 45 return &x + c; 46} 47 48int h(void) 49{ 50 return c + *f(&x); 51} 52 53 54