iswspace(3)
β¨ iswspace(3) β¨ β Library Functions Manual π«Ά
okay bestie, pull up a chair, we're learning about iswspace π
this one is a whole icon in the wide-character world and honestly it's giving "quietly essential" energy.
πΈ NAME πΈ
iswspace β test for whitespace wide character
π LIBRARY π
Standard C library (libc, -lc) β yeah, the classic, no cap π
β¨ SYNOPSIS β¨
#include <wctype.h>
int iswspace(wint_t wc);
π DESCRIPTION π
okay so first things first: iswspace() is literally the wide-character equivalent of the isspace(3) function. that's it, that's the vibe. it tests whether wc is a wide character belonging to the wide-character class "space". π
now here's the lore. the wide-character class "space" is disjoint from the wide-character class "graph", which means it's also disjoint from all of graph's subclasses: "alnum", "alpha", "upper", "lower", "digit", "xdigit", and "punct". so no overlap bestie, they do not run in the same circles π
meanwhile, the wide-character class "space" contains the wide-character class "blank". so blank is like... a sub-vibe. a little subset. cute. π
and here's the part that's fr fr important: the wide-character class "space" always contains at least the space character and these control characters: '\f', '\n', '\r', '\t', and '\v'. β like, bare minimum, this is the roster.
π RETURN VALUE π
iswspace()returns nonzero ifwcis a wide character that belongs to the wide-character class "space". slay. β- otherwise it returns zero. not it. π
π ATTRIBUTES π
for an explanation of the terms used in this section, go peek at attributes(7) bestie.
- Interface:
iswspace() - Attribute: Thread safety
- Value:
MT-Safe locale
so like, it's thread safe, but locale-flavored thread safe. iykyk π¦
π STANDARDS π
C11, POSIX.1-2008.
π°οΈ HISTORY π°οΈ
POSIX.1-2001, C99. so it's been around for a minute, an OG fr fr.
π§ NOTES π§
the behavior of iswspace() depends on the LC_CTYPE category of the current locale. so like, change your locale, change the answer. π
real talk: this function is locale-sensitive, so don't act surprised when the result shifts depending on where you are. π
π₯ SEE ALSO π₯
okay that's the whole page, you ate that π«Ά this little deep-dive brought to you by Linux man-pages 6.20, dated 2026-02-08, for iswspace(3). go forth and check your whitespace, bestie πβ¨
π¦ where this page comes from
- arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages 6.20
- π the page's license: GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms