Use Py_IS_TYPE on abi3 & python 3.15+#5977
Conversation
eb1faa7 to
2cecf6d
Compare
ngoldbaum
left a comment
There was a problem hiding this comment.
This also follows how CPython spells these check macros.
I seriously doubt adding one extra function call that can be inlined matters for non-limited API builds, but I'll defer to @davidhewitt to give this a look and hit the merge button.
|
@davidhewitt Any concerns? |
davidhewitt
left a comment
There was a problem hiding this comment.
Definitely an improvement and matches CPython better too 🎉
There was a problem hiding this comment.
I would probably drop the newsfragment, seems like ultimately this is a refactoring that doesn't have external effect (yet)?
|
Thanks! |
f4cd954 to
7211866
Compare
Merging this PR will not alter performance
Comparing Footnotes
|
* Use `Py_IS_TYPE` on abi3 & python 3.15+ * Delete changelog
Avoid raw pointer comparison on ABI3 when
Py_IS_TYPEis available.xref RustPython/RustPython#7562