Skip to content

Conversation

@vstinner
Copy link
Member

@vstinner vstinner commented May 31, 2024

@vstinner
Copy link
Member Author

cc @colesbury @corona10

Copy link
Member

@corona10 corona10 left a comment

Choose a reason for hiding this comment

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

lgtm

@vstinner
Copy link
Member Author

  • Python.h includes object.h before refcount.h.
  • object.h refers to 2 macros defined in refcount.h: PyObject_HEAD_INIT refers to _Py_IMMORTAL_REFCNT_LOCAL and PyObject_HEAD_INIT refers to _Py_IMMORTAL_REFCNT. It works since the macro is not expanded before refcount.h is included.

@vstinner
Copy link
Member Author

I prefer to not backport this change to 3.13, but it can make backport from 3.14 to 3.13 more complicated (doable, it's just more manual work if Git fails to track code move).

@corona10
Copy link
Member

IMO, Backporting to 3.13 is worth doing it since we modified a lot of code at 3.13

@vstinner
Copy link
Member Author

IMO, Backporting to 3.13 is worth doing it since we modified a lot of code at 3.13

IMO it's too later after beta1.

@vstinner vstinner changed the title gh-119853: Add Include/refcount.h file gh-119853: Add Include/refcount.h file May 31, 2024
@vstinner vstinner changed the title gh-119853: Add Include/refcount.h file gh-119853: Add Include/refcount.h file May 31, 2024
@vstinner vstinner merged commit 891c1e3 into python:main May 31, 2024
@vstinner vstinner deleted the refcount branch May 31, 2024 14:49
@vstinner
Copy link
Member Author

Merged, thanks for the review. I don't plan to backport the change to 3.13 since we are past the feature freeze.

@vstinner
Copy link
Member Author

Oh, I forgot to add the header file to projects: #119860

noahbkim pushed a commit to hudson-trading/cpython that referenced this pull request Jul 11, 2024
estyxx pushed a commit to estyxx/cpython that referenced this pull request Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants