From d122b1cc731dd279337fc1f8119667e1a4356f72 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Thu, 3 Apr 2003 08:26:07 +0000 Subject: * libc/include/wchar.h: Add definition for wcscoll. * libc/string/Makefile.am: Add wcscoll.c. * libc/string/Makefile.in: Regenerated. * libc/string/wcscoll.c: New file. * libc/string/wcstrings.tex: Add wcscoll. --- newlib/libc/string/wcscoll.c | 48 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 newlib/libc/string/wcscoll.c (limited to 'newlib/libc/string/wcscoll.c') diff --git a/newlib/libc/string/wcscoll.c b/newlib/libc/string/wcscoll.c new file mode 100644 index 000000000..fb656521a --- /dev/null +++ b/newlib/libc/string/wcscoll.c @@ -0,0 +1,48 @@ +/* +FUNCTION + <>---locale specific wide-character string compare + +INDEX + wcscoll + +ANSI_SYNOPSIS + #include + int wcscoll(const char *<[stra]>, const char * <[strb]>); + +TRAD_SYNOPSIS + #include + int wcscoll(<[stra]>, <[strb]>) + char *<[stra]>; + char *<[strb]>; + +DESCRIPTION + <> compares the wide-character string pointed to by + <[stra]> to the wide-character string pointed to by <[strb]>, + using an interpretation appropriate to the current <> + state. + + The current implementation of <> simply uses <> + and does not support any language-specific sorting. + +RETURNS + If the first string is greater than the second string, + <> returns a number greater than zero. If the two + strings are equivalent, <> returns zero. If the first + string is less than the second string, <> returns a + number less than zero. + +PORTABILITY +<> is ISO/IEC 9899/AMD1:1995 (ISO C). +*/ + +#include <_ansi.h> +#include + +int +_DEFUN (wcscoll, (a, b), + _CONST wchar_t *a _AND + _CONST wchar_t *b) + +{ + return wcscmp (a, b); +} -- cgit v1.2.3