gh-141004: Document remaining PyCF compiler flag macros#153958
Conversation
Document PyCF_DONT_IMPLY_DEDENT, PyCF_IGNORE_COOKIE, PyCF_SOURCE_IS_UTF8, PyCF_MASK and PyCF_COMPILE_MASK in the PyCompilerFlags section, with examples.
Documentation build overview
7 files changed ·
|
ZeroIntensity
left a comment
There was a problem hiding this comment.
We should say somewhere in here that users should generally avoid these.
| PyCF_DONT_IMPLY_DEDENT | ||
| PyCF_IGNORE_COOKIE | ||
| PyCF_MASK | ||
| PyCF_MASK_OBSOLETE |
There was a problem hiding this comment.
Can we also document this one?
There was a problem hiding this comment.
Clauding on that, yes
There was a problem hiding this comment.
As asked, I documented PyCF_ALLOW_INCOMPLETE_INPUT (cc @pablogsal) and PyCF_MASK_OBSOLETE.
Both entries lead with a caution against using the flag. Remove the two names from the C API docs ignore list.
Introduce them with a note that code outside the standard library rarely needs them, and title the masks group for symmetry.
The masks serve the same narrow needs as the flags, so drop their separate rubric and let the low-level introduction apply to both.
|
Thanks @johnslavik for the PR, and @ZeroIntensity for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14, 3.15. |
|
GH-153984 is a backport of this pull request to the 3.15 branch. |
|
GH-153985 is a backport of this pull request to the 3.14 branch. |
|
GH-153986 is a backport of this pull request to the 3.13 branch. |
Document PyCF_DONT_IMPLY_DEDENT, PyCF_IGNORE_COOKIE, PyCF_SOURCE_IS_UTF8, PyCF_MASK and PyCF_COMPILE_MASK in the PyCompilerFlags section, with examples.