// S : tags libc c // S : expect --result valid // S : cc -o test.bc -D_PDCLIB_BUILD -DTEST $file // S : verify -o nofail:malloc -o nofail:vfs test.bc #include #include "_PDCLIB_test.h" int main( void ) { char const xxxxx[] = "xxxxx"; TESTCASE( memcmp( abcde, abcdx, 5 ) < 0 ); TESTCASE( memcmp( abcde, abcdx, 4 ) == 0 ); TESTCASE( memcmp( abcde, xxxxx, 0 ) == 0 ); TESTCASE( memcmp( xxxxx, abcde, 1 ) > 0 ); return 0; }