FPCLASSIFY(3P)

πŸ’– FPCLASSIFY(3P) πŸ’–

okay bestie, welcome to the POSIX Programmer's Manual entry for fpclassify β€” she's giving "classify real floating type" and she's lowkey a whole vibe. πŸ¦‹


✨ PROLOG ✨

so like, real talk first: this manual page is part of the POSIX Programmer's Manual. the Linux implementation of this interface may differ (bestie, go consult the corresponding Linux manual page for the details on Linux behavior), or honestly the interface may just not be implemented on Linux at all. it's giving mystery. πŸ’€


🌸 NAME 🌸

fpclassify β€” classify real floating type. periodt. that's the whole job. πŸ‘‘


πŸŽ€ SYNOPSIS πŸŽ€

#include <math.h>

int fpclassify(real-floating x);

like yes, that's it, that's the whole thing, she's compact and she knows it ✨


πŸ’… DESCRIPTION πŸ’…

so 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 β€” nobody's trying to start drama. this volume of POSIX.1‐2017 defers to the ISO C standard. respect the hierarchy, bestie. 🫢

the fpclassify() macro shall classify its argument value as:

  • NaN
  • infinite
  • normal
  • subnormal
  • zero
  • or into another implementation-defined category

okay and here's the order of operations, iykyk: first, an argument represented in a format wider than its semantic type is converted to its semantic type. then classification is based on the type of the argument. it's giving "narrow it down, then judge it." πŸ’…


⭐ RETURN VALUE ⭐

the fpclassify() macro shall return the value of the number classification macro appropriate to the value of its argument. so like, you hand her a number, she hands you back the correct label. no cap, that's the whole relationship. πŸŽ€


🌈 ERRORS 🌈

No errors are defined.

and just so you know: the following sections are informative. not the law, just the lore. πŸ’œ


πŸ“ EXAMPLES πŸ“

None.

(it's giving minimalism, and honestly? respect.) 😌


🧚 APPLICATION USAGE 🧚

None.


πŸ¦‹ RATIONALE πŸ¦‹

None.


πŸ’œ FUTURE DIRECTIONS πŸ’œ

None.


πŸ‘‘ SEE ALSO πŸ‘‘

  • isfinite()
  • isinf()
  • isnan()
  • isnormal()
  • signbit()

The Base Definitions volume of POSIX.1‐2017, <math.h>

go read those too bestie, they're the friend group πŸ’–


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 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 .

okay so pls do not come for me about typos β€” those were almost definitely added during the conversion to man page format, and there's a whole link above for reporting them. be nice. πŸ™ˆ

and that's the whole page, bestie!! this one came from IEEE/The Open Group, 2017 β€” FPCLASSIFY(3P), the one and only. slay, stay classified, and don't forget to narrow your semantic type before you judge. πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from