bpo-40170: Hide implementation detail of Py_TRASHCAN_BEGIN macro#23235
bpo-40170: Hide implementation detail of Py_TRASHCAN_BEGIN macro#23235vstinner merged 6 commits intopython:masterfrom
Conversation
|
cc @vstinner |
Doc/whatsnew/3.10.rst
Outdated
| * The ``Py_TRASHCAN_BEGIN`` macro no longer accesses PyTypeObject attributes, | ||
| but now can get the condition by calling the new private | ||
| :c:func:`_PyTrash_cond()` function which hides implementation details. | ||
| (Contributed by Hai Shi in :issue:`40170`.) |
There was a problem hiding this comment.
I don't think that it's worth it to mention in What's New in Python 3.10. End users will not notice and don't care ;-)
There was a problem hiding this comment.
Ok, removed.
I decided add this news because I saw you have written the description info of _PyTrash_begin() and _PyTrash_end() in whatsnew. Lol~
There was a problem hiding this comment.
I wrote a changelog entry, but nothing in What's New in Python 3.9 or What's New in Python 3.10, no?
There was a problem hiding this comment.
Oh, I saw this info in https://github.com/python/cpython/blob/master/Misc/NEWS.d/3.9.0a5.rst.
Looks like I confused the news file with relese file : (, sorry.
There was a problem hiding this comment.
No problem.
I consider that "What's New in Python X.Y" should be short and only describe the public API, but the Changelog should describe every single change and private functions can be mentioned there.
There was a problem hiding this comment.
Oh, This great. I am very confused when I start write the whatsnew file in the first time.
It's more like a double copy operation.
In fact, I don't know how release manager to archieve those change log.
My simple thought: Maybe we can create some labels to tag what's info should be added in release file or not. When release manager archive those change log, those taged changeinfo chould be archieved in release file automatically.
If this thought have any value, I can add this in my TODO list. Lol~
|
@vstinner Hi, victor. Is this PR good enough to be merged? |
vstinner
left a comment
There was a problem hiding this comment.
LGTM, but please address my last minor request (just add a comment).
| } | ||
|
|
||
|
|
||
| int |
There was a problem hiding this comment.
Please add comment explaining that it is used by the Py_TRASHCAN_BEGIN macro.
|
Merged, thanks. |
|
Thanks, victor. |
The Py_TRASHCAN_BEGIN macro no longer accesses PyTypeObject attributes, but now can get the condition by calling the new private _PyTrash_cond() function which hides implementation details.
https://bugs.python.org/issue40170