Uh oh!
There was an error while loading. Please reload this page.
gh-98410: move getbufferproc and releasebufferproc to buffer.h - #31158
Conversation
17e73b3 to
7c6bb60CompareClosing as the buffer protocol is available in 3.11 in Limited C API. |
@kumaraditya303 can I please push for you to consider reopening and reviewing this patch? The point that the buffer protocol is available in 3.11 is exactly why I think this should be merged. As of current 3.11 release on the limited API I can call (And equivalent for |
kumaraditya303
commented
Oct 12, 2022
@davidhewitt Sorry for closing your PR. I reopened it and you are correct that the function typedefs are not exposed. I would suggest you to create issue for this issue to discuss this first, nobody looked at this because no issue was mentioned and there are conflicts and and this can't be fixed in 3.11 as the rc is out and final is about to be released. There are conflicts in this PR, I would suggest you create a new PR with fixed conflicts but it's your choice if you want to continue with this one. |
davidhewitt
commented
Oct 18, 2022
@kumaraditya303 thanks very much - I have opened #98410 and I'm happy to spend the time to rebase this PR once someone has suggested that a change of this nature would potentially be suitable to merge. |
encukou
commented
Oct 24, 2022
Thanks for the catch! Let me know if you want more info, or if you'd prefer to leave this to me. |
davidhewitt
commented
Oct 25, 2022
Thanks - I'll do my best to find a moment to tidy this up tonight! |
7c6bb60 to
a11ce47Comparedavidhewitt
commented
Oct 25, 2022
@encukou how does that look? |
75b0e16 to
eae6de2Compareeae6de2 to
a768db1Comparedavidhewitt
commented
Oct 28, 2022
rebased |
encukou
commented
Oct 31, 2022
Looks good, thank you! but with typedefs, we can relax this rule a little: they'll be available to people building for 3.11 using 3.12. |
After #29991 it is possible to set
Py_bf_getbufferandPy_bf_releasebufferslots from the stable API.This PR moves the corresponding typedefs for the function pointer types corresponding to these slots from
Include/cpython/object.hto be alongside other typedefs inInclude/pybuffer.h.This may be useful for users who wish to cast to these function pointer types.
getbufferprocandreleasebufferprocto the limited API headers #98410