fixes for host gcc 4.6.1
[zpugcc/jano.git] / toolchain / gcc / newlib / libc / string / bcmp.c
blob23e7c26a22fc46b258ab23cc900c9db680c2618c
1 /*
2 FUNCTION
3 <<bcmp>>---compare two memory areas
5 INDEX
6 bcmp
8 ANSI_SYNOPSIS
9 #include <string.h>
10 int bcmp(const void *<[s1]>, const void *<[s2]>, size_t <[n]>);
12 TRAD_SYNOPSIS
13 #include <string.h>
14 int bcmp(<[s1]>, <[s2]>, <[n]>)
15 const void *<[s1]>;
16 const void *<[s2]>;
17 size_t <[n]>;
19 DESCRIPTION
20 This function compares not more than <[n]> bytes of the
21 object pointed to by <[s1]> with the object pointed to by <[s2]>.
23 This function is identical to <<memcmp>>.
27 RETURNS
28 The function returns an integer greater than, equal to or
29 less than zero according to whether the object pointed to by
30 <[s1]> is greater than, equal to or less than the object
31 pointed to by <[s2]>.
33 PORTABILITY
34 <<bcmp>> requires no supporting OS subroutines.
36 QUICKREF
37 bcmp ansi pure
40 #include <string.h>
42 int
43 _DEFUN (bcmp, (m1, m2, n),
44 _CONST void *m1 _AND
45 _CONST void *m2 _AND
46 size_t n)
49 return memcmp (m1, m2, n);