FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-101100: Fix Sphinx warnings in `c-api/float.rst` by hugovk · Pull Request #113494 · python/cpython · GitHub

Repository navigation

gh-101100: Fix Sphinx warnings in c-api/float.rst - #113494

Closed
hugovk wants to merge 1 commit into
python:mainfrom
hugovk:docs-fix-sphinx-warnings-float
Closed

hugovk wants to merge 1 commit into
python:mainfrom
hugovk:docs-fix-sphinx-warnings-float

Conversation

hugovk commented Dec 26, 2023 •
edited by github-actions Bot
Loading

Copy link
Copy Markdown
Member

Fix these warnings by documenting the constant:

Doc/c-api/float.rst:109: WARNING: c:macro reference target not found: PY_BIG_ENDIAN
Doc/c-api/float.rst:140: WARNING: c:macro reference target not found: PY_BIG_ENDIAN

📚 Documentation preview 📚: https://cpython-previews--113494.org.readthedocs.build/

serhiy-storchaka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

If you document PY_BIG_ENDIAN, you should also document PY_LITTLE_ENDIAN.

And I think that float.rst is a wrong place for this. They have little relation to floats. Actually, the endianess of floating point representation can be different from the endianess of integer representation (see DOUBLE_IS_BIG_ENDIAN_IEEE754, DOUBLE_IS_LITTLE_ENDIAN_IEEE754 and DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754).

hugovk commented Dec 27, 2023

Copy link
Copy Markdown
Member Author

Good point, these constants are defined in pyport.h, nothing to do with floats.

What do you recommend?

  • Document the constants elsewhere - where?
  • Silence these warnings with !
  • Keep the warnings

Copy link
Copy Markdown
Member

I do not know what is the best place for them, this is why they are still not documented. I suggest to leave this as is, until we found good place (many other macros are not documented).

hugovk commented Dec 27, 2023

Copy link
Copy Markdown
Member Author

Fine by me, let's tackle these later. Thanks for the review!

hugovk closed this Dec 27, 2023
hugovk deleted the docs-fix-sphinx-warnings-float branch December 23, 2025 11:34
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting core review docs Documentation in the Doc dir needs backport to 3.11 only security fixes needs backport to 3.12 only security fixes skip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL