8000 gh-95914: Add What's New item describing PEP 670 changes by CAM-Gerlach · Pull Request #98315 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-95914: Add What's New item describing PEP 670 changes #98315

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 17, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Apply requested changes from Victor and Kumar to PEP 670 section
Co-authored-by: Victor Stinner <vstinner@python.org>
  • Loading branch information
CAM-Gerlach and vstinner authored Oct 17, 2022
commit 8fad67cb543aa6e4d68ff579bc01d04b41f259a3
12 changes: 6 additions & 6 deletions Doc/whatsnew/3.11.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1884,16 +1884,16 @@ New Features
Porting to Python 3.11
----------------------

* Many macros have been converted to functions in the Python C API,
making them usable from other programming languages and avoiding
`macro pitfalls <https://gcc.gnu.org/onlinedocs/cpp/Macro-Pitfalls.html>`_
* Some macros have been converted to static inline functions to avoid
`macro pitfalls <https://gcc.gnu.org/onlinedocs/cpp/Macro-Pitfalls.html>`_.
The change should be mostly transparent to users,
as the replacement functions will cast their arguments to the expected types
to avoid compiler warnings due to static type checks.
However, when the limited C API is set to >=3.11, these casts are not done,
and callers will need to cast arguments to their expected values.
However, when the limited C API is set to >=3.11,
these casts are not done,
and callers will need to cast arguments to their expected types.
See :pep:`670` for more details.
(Contributed by Victor Stinner in :gh:`89653`.)
(Contributed by Victor Stinner and Erlend E. Aasland in :gh:`89653`.)

* :c:func:`PyErr_SetExcInfo()` no longer uses the ``type`` and ``traceback``
arguments, the interpreter now derives those values from the exception
Expand Down
0