]>
git.saurik.com Git - apple/dyld.git/blob - unit-tests/test-cases/re-export-symbol-dylib/main.c
2 #include <stdio.h> // fprintf(), NULL
3 #include <stdlib.h> // exit(), EXIT_SUCCESS
6 #include "test.h" // PASS(), FAIL(), XPASS(), XFAIL()
18 int (*pfrob
)() = &frob
;
24 FAIL("re-export-symbol-dylib: foo() returned wrong value");
25 else if ( bar() != 2 )
26 FAIL("re-export-symbol-dylib: bar() returned wrong value");
27 else if ( baz() != 3 )
28 FAIL("re-export-symbol-dylib: baz() returned wrong value");
29 else if ( frob() != 4 )
30 FAIL("re-export-symbol-dylib: frob() returned wrong value");
32 else if ( (*pfoo
)() != 1 )
33 FAIL("re-export-symbol-dylib: (*pfoo)() returned wrong value");
34 else if ( (*pbar
)() != 2 )
35 FAIL("re-export-symbol-dylib: (*pbar)() returned wrong value");
36 else if ( (*pbaz
)() != 3 )
37 FAIL("re-export-symbol-dylib: (*pbaz)() returned wrong value");
38 else if ( (*pfrob
)() != 4 )
39 FAIL("re-export-symbol-dylib: (*pfrob)() returned wrong value");
41 PASS("re-export-symbol-dylib");