revised isfinite, _finite, and _finitef documentation - #5962
Conversation
this corrects some information of the `isfinite`, `_finite`, and `_finitef` reference page: the current page lists `<math.h>` and `<cmath>` as valid headers for `_finite` even though the current UCRT declares it only through `<float.h>` and `<cfloat>`. its remarks section also name x86 instead of x64 as a supported `_finitef` target, while the UCRT implementation disagrees. the return value section benignly omitted signed zeros. this revision addresses the C and C++ header requirements, and makes it evident that normal numbers, subnormal numbers, and **both signed zeros** are finite.
|
Eulernion : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. |
|
Eulernion : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. |
|
Learn Build status updates of commit 68801be: ✅ Validation status: passed
For more details, please refer to the build report. |
|
Can you review the proposed changes? IMPORTANT: When the changes are ready for publication, adding a #label:"aq-pr-triaged" |
|
Regan Downer (@v-regandowner) I take it the note was meant for me; as such: #sign-off |
|
Eulernion - No, in the public repo, pull requests should only be signed off by the author/owner. Tyler Whitney (@TylerMSFT) - Could you take a look? Thanks! |
Tyler Whitney (TylerMSFT)
left a comment
There was a problem hiding this comment.
Thank you for updating this.
|
#sign-off |
Tyler Whitney (TylerMSFT)
left a comment
There was a problem hiding this comment.
Thank you for the update!
Minor wordsmithing
|
Learn Build status updates of commit 898bca0: ✅ Validation status: passed
For more details, please refer to the build report. |
|
#sign-off |
There was a problem hiding this comment.
🟡 Changes recommended
Unresolved platform, metadata, and documentation-style issues remain.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Updates CRT documentation for isfinite, _finite, and _finitef.
Changes:
- Corrects C and C++ header requirements.
- Documents both signed zeros as finite.
- Updates
_finitefplatform information.
File summaries
| File | Review summary |
|---|---|
docs/c-runtime-library/reference/finite-finitef.md |
Requires updates for ARM64EC syntax, frontmatter metadata, and lowercase nan. |
Review details
Suppressed comments (1)
docs/c-runtime-library/reference/finite-finitef.md:45
- Use lowercase in the spelled-out form of
NaN; the documentation style reserves capitalization for proper nouns.
The `isfinite` macro and the `_finite` and `_finitef` functions return a non-zero value if *`x`* is a normal, subnormal, or signed zero (`±0`) finite value. They return 0 if the argument is infinite or Not a Number (NaN). The C++ inline template function `isfinite` behaves the same way but returns **`true`** or **`false`**.
- Files reviewed: 1/1 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
|
||
| `isfinite` is a macro when compiled as C, and an inline template function when compiled as C++. | ||
|
|
||
| `_finitef` is only available when compiling for the x64, ARM, ARM64, or ARM64EC platforms. |
| ## Return value | ||
|
|
||
| The `isfinite` macro and the `_finite` and `_finitef` functions return a non-zero value if *`x`* is either a normal or subnormal finite value. They return 0 if the argument is infinite or a NaN. The C++ inline template function `isfinite` behaves the same way, but returns **`true`** or **`false`**. | ||
| The `isfinite` macro and the `_finite` and `_finitef` functions return a non-zero value if *`x`* is a normal, subnormal, or signed zero (`±0`) finite value. They return 0 if the argument is infinite or Not a Number (NaN). The C++ inline template function `isfinite` behaves the same way but returns **`true`** or **`false`**. |
530c251
into
MicrosoftDocs:main
this corrects some information of the
isfinite,_finite, and_finitefreference page: the current page lists<math.h>and<cmath>as valid headers for_finiteeven though the current UCRT declares it only through<float.h>and<cfloat>. its remarks section also name x86 instead of x64 as a supported_finiteftarget, while the UCRT implementation disagrees. the return value section benignly omitted signed zeros. this revision addresses the C and C++ header requirements, and makes it evident that normal numbers, subnormal numbers, and both signed zeros are finite.