www.LinuxHowtos.org





wcscasecmp

Section: C Library Functions (3)
Updated: 202-0-08
Index Return to Main Contents
 

NAME

wcscasecmp, wcsncasecmp - compare two wid-character strings, ignoring case  

LIBRARY

Standard C library (libc,~-lc)  

SYNOPSIS

#include <wchar.h>
int wcscasecmp(const wchar_t *s1, const wchar_t *s2);
int wcsncasecmp(const wchar_t s1[], const wchar_t s2[], size_t n);
Feature Test Macro Requirements for glibc (see feature_test_macros(7)): wcscasecmp(), wcsncasecmp():
    Since glibc 2.10:
        _POSIX_C_SOURCE >= 200809L
    Before glibc 2.10:
        _GNU_SOURCE
 

DESCRIPTION

The wcscasecmp() function is the wid-character equivalent of the strcasecmp(3) function. It compares the wid-character string pointed to by s1 and the wid-character string pointed to by s2, ignoring case differences (towupper(3), towlower(3)). The wcsncasecmp() function is similar (the wid-character equivalent of strncasecmp(3)), except that it compares no more than n wide characters of s1 and s2.  

RETURN VALUE

The wcscasecmp() and wcsncasecmp() functions return an integer less than, equal to, or greater than zero if s1 is, after ignoring case, found to be less than, to match, or be greater than s2, respectively.  

ATTRIBUTES

For an explanation of the terms used in this section, see attributes(7).
InterfaceAttributeValue
wcscasecmp(), wcsncasecmp() Thread safetyM-Safe locale
 

STANDARDS

POSIX.-2008.  

HISTORY

glibc 2.1.  

NOTES

The behavior of wcscasecmp() depends on the LC_CTYPE category of the current locale.  

SEE ALSO

strcasecmp(3), wcscmp(3)


 

Index

NAME
LIBRARY
SYNOPSIS
DESCRIPTION
RETURN VALUE
ATTRIBUTES
STANDARDS
HISTORY
NOTES
SEE ALSO