mc-manual.xml fix new/delete expresions -> expression
[valgrind.git] / none / tests / discard.c
blob3a1fc653dc209c24dbfb47976280a5a43c041da6
2 #include <stdio.h>
3 #include "../../include/valgrind.h"
8 int fooble ( void )
10 int x, y;
11 y = 0;
12 for (x = 0; x < 100; x++) {
13 if ((x % 3) == 0) y += x; else y++;
15 return y;
18 void someother ( void )
22 int main ( void )
24 printf("fooble-1() = %d\n", fooble() );
25 VALGRIND_DISCARD_TRANSLATIONS( (char*)(&fooble),
26 ((char*)(&someother)) - ((char*)(&fooble)) );
27 printf("fooble-2() = %d\n", fooble() );
28 return 0;