blob: 0d7aa2bbc29b5c0eed8933c83ba27b9ed1e07b90 [file] [log] [blame]
// RUN: test.sh -p -t %t %s
#include <string.h>
#include <assert.h>
// This is an example of the correct usage of memchr().
int main()
{
char c[8] = "ABCADEF";
char *pt;
pt = memchr(&c[1], 'A', 4);
assert(pt == &c[3]);
return 0;
}