Various minor fixes for compiler/linter (other then splint itself) warnings.
[splint-patched.git] / test / iter2.c
blob8011373be10b04bbc0d75a3e7bb97993aba9c427
1 # include "iter2.h"
3 int test (void)
5 char c;
6 int i;
7 int *a;
9 intFor(2,5,x,z) /* 1. unrecognized identifier: x */
11 printf("%d\n", z);
12 } end_intFor;
14 intFor(2,c,x,i) /* 2, 3, 5. yield param shadows local, variable i declared but not used, type mismatch c */
17 } ; /* 4. not balanced with end_intFor */
19 intFor(2,12,x,i+3) /* 6, 7. use i before def, yield param not simple */
22 } end_arrayElements; /* 8. not balanced with end_intFor */
24 arrayElements(1, 10, a, el)
26 printf("%d\n", el);
27 } end_arrayElements;
28 return 3;