WCSCOLL(3)

πŸ“¦
version 15.1 Β· 2 versions
, in freebsd 15.1

πŸ’… WCSCOLL(3) β€” Library Functions Manual ✨

okay so bestie, welcome to the Library Functions Manual page for WCSCOLL(3) β€” the wide-string collation girlie herself. she’s here to compare wide strings the locale-correct way, and yes, she ate. πŸŽ€

πŸŽ€ NAME πŸŽ€

wcscoll β€” compare wide strings according to current collation. that’s the whole name, no cap. ✨

πŸ“š LIBRARY πŸ“š

She lives in the Standard C Library (libc, -lc) β€” yes, that’s the whole library flex. πŸ’–

🌸 SYNOPSIS 🌸

#include <wchar.h>

int
wcscoll(const wchar_t *s1, const wchar_t *s2);

πŸ¦‹ DESCRIPTION πŸ¦‹

The wcscoll() function compares the null-terminated strings s1 and s2 according to the current locale collation order. literally what she said. πŸ¦‹

In the β€œC” locale, wcscoll() is equivalent to wcscmp(). iykyk. πŸ’…

🫢 RETURN VALUES 🫢

The wcscoll() function returns an integer greater than, equal to, or less than 0, if s1 is greater than, equal to, or less than s2. yes, she’s giving comparison-result main character energy. πŸ‘‘

No return value is reserved to indicate errors; callers should set errno to 0 before calling wcscoll(). If it is non-zero upon return from wcscoll(), an error has occurred. so like, check errno, bestie β€” that’s the vibe check. 🚨

πŸ’€ ERRORS πŸ’€

The wcscoll() function will fail if:

  • [EILSEQ] β€” An invalid wide character code was specified. 😭
  • [ENOMEM] β€” Cannot allocate enough memory for temporary buffers. πŸ’€

πŸ¦‹ SEE ALSO πŸ¦‹

go read the sisters, bestie. 🫢

🌈 STANDARDS 🌈

The wcscoll() function conforms to ISO/IEC 9899:1999 (β€œISO C99”). certified iconic. βœ…

πŸ™ˆ BUGS πŸ™ˆ

The current implementation of wcscoll() only works in single-byte LC_CTYPE locales, and falls back to using wcscmp() in locales with extended character sets. okay so this is the real tea: single-byte LC_CTYPE locales? she works. locales with extended character sets? she falls back to wcscmp(). ⚠️


mwah πŸ’‹ β€” this page is from Debian, dated October 4, 2002, and the page is WCSCOLL(3). periodt. πŸ‘‘

πŸ“¦ where this page comes from
  • freebsd 15.1: base 15.1
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms