ISWUPPER(3POSIX)
๐ ISWUPPER(3POSIX) โ the POSIX Programmer's Manual page, bestie edition โจ
okay so this is iswupper(3POSIX), straight out of the POSIX Programmer's Manual, and we're about to make character classification make sense. no cap. ๐ซถ
๐ธ PROLOG ๐ธ
bestie, real talk first: this manual page is part of the POSIX Programmer's Manual. the Linux implementation of this interface may differ (so like, go check the corresponding Linux manual page for the deets on Linux behavior), or honestly the interface may not even be implemented on Linux at all. ๐ so don't come for me if your system's doing its own thing.
โจ NAME โจ
iswupper, iswupper_l โ test for an uppercase letter wide-character code. that's the whole vibe. ๐
๐ฆ SYNOPSIS ๐ฆ
#include <wctype.h>
int iswupper(wint_t wc);
int iswupper_l(wint_t wc, locale_t locale);
look at that. two little functions. iconic. ๐
๐ DESCRIPTION ๐
so for iswupper(): the functionality described on this reference page is aligned with the ISO C standard. any conflict between the requirements described here and the ISO C standard is unintentional โ like, not on purpose at all. this volume of POSIX.1โ2017 defers to the ISO C standard. periodt. ๐ซก
the iswupper() and iswupper_l() functions shall test whether wc is a wide-character code representing a character of class upper in the current locale, or in the locale represented by locale, respectively. (if you wanna know what a locale even is, go see the Base Definitions volume of POSIX.1โ2017, Chapter 7, Locale. it's giving required reading. ๐)
now, the wc argument is a wint_t, and the value of it โ your application shall make sure it's a wide-character code corresponding to a valid character in the locale used by the function, or equal to the value of the macro WEOF. that's the assignment, bestie.
๐จ if the argument has any other value, the behavior is undefined. not "kinda weird", not "a little off" โ undefined. we don't go there. ๐
and one more thing, highkey important:
๐จ the behavior is undefined if thelocaleargument toiswupper_l()is the special locale objectLC_GLOBAL_LOCALEor is not a valid locale object handle. so like, don't. ๐
๐ RETURN VALUE ๐
the iswupper() and iswupper_l() functions shall return non-zero if wc is an uppercase letter wide-character code; otherwise, they shall return 0. that's it. binary queen energy. ๐
๐ ERRORS ๐
no errors are defined. slay, honestly. nothing to worry about here. โจ
the following sections are informative โ aka, they're here to help, not to boss you around. ๐ง
๐ EXAMPLES ๐
None. (yes, literally none. we're keeping it real.) ๐ญ
๐ APPLICATION USAGE ๐
to ensure applications portability โ especially across natural languages, which is a whole thing โ only these functions and the functions in the reference pages listed in the SEE ALSO section should be used for character classification. iykyk. ๐
๐ง RATIONALE ๐ง
None. moving on, bestie. ๐
๐ฎ FUTURE DIRECTIONS ๐ฎ
None. the future is bright and empty of changes here. โญ
๐ฅ SEE ALSO ๐ฅ
go read these too, they're all part of the same friend group:
iswalnum()iswalpha()iswcntrl()iswctype()iswdigit()iswgraph()iswlower()iswprint()iswpunct()iswspace()iswxdigit()setlocale()uselocale()
also, the Base Definitions volume of POSIX.1โ2017, Chapter 7, Locale, plus the headers <locale.h> and <wctype.h>. ๐ซถ
โ๏ธ COPYRIGHT โ๏ธ
okay legal moment, but make it cute:
portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1-2017, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 7, 2018 Edition, Copyright (C) 2018 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group.
in the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. (the original is the main character, basically. ๐) the original Standard can be obtained online at http://www.opengroup.org/unix/online.html .
any typographical or formatting errors that appear in this page are most likely to have been introduced during the conversion of the source files to man page format. to report such errors, see https://www.kernel.org/doc/man-pages/reporting_bugs.html . ๐
and that's the whole page, bestie!! this masterpiece was brought to you by IEEE/The Open Group, dated 2017, and it's the ISWUPPER(3POSIX) page โ thanks for reading, ily, go classify some characters responsibly. ๐โจ๐๐ฆ
๐ฆ where this page comes from
- debian bookworm: manpages-posix-dev 2017a-2 ยท Other
- debian trixie: manpages-posix-dev 2017a-2 ยท Other
- ubuntu jammy: manpages-posix-dev 2017a-2 ยท Other
- ubuntu noble: manpages-posix-dev 2017a-2 ยท Other
- ubuntu resolute: manpages-posix-dev 2017a-2build1 ยท Other
- ubuntu stonking: manpages-posix-dev 2017a-2.1 ยท Other
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms