Skip to content

Remove check for stdarg.h (HAVE_STDARG_PROTOTYPES) in configure.ac #93207

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

Closed
kumaraditya303 opened this issue May 25, 2022 · 4 comments · Fixed by #93215
Closed

Remove check for stdarg.h (HAVE_STDARG_PROTOTYPES) in configure.ac #93207

kumaraditya303 opened this issue May 25, 2022 · 4 comments · Fixed by #93215
Assignees
Labels
3.12 only security fixes build The build process and cross-build type-bug An unexpected behavior, bug, or error

Comments

@kumaraditya303
Copy link
Contributor

kumaraditya303 commented May 25, 2022

CPython checks for stdarg.h as HAVE_STDARG_PROTOTYPES 1 at some places 2 but not at other places 3. Either this check should be repeated at every call site or should be removed all together, most compilers supports this nowadays (should be verified with buildbots).

cc @vstinner @tiran @erlend-aasland

Footnotes

  1. https://github.com/python/cpython/blob/16a7e4a0b75080275bf12cfb71d54b01d85099b2/configure.ac#L5026

  2. https://github.com/python/cpython/blob/16a7e4a0b75080275bf12cfb71d54b01d85099b2/Modules/_asynciomodule.c#L2646

  3. https://github.com/python/cpython/blob/16a7e4a0b75080275bf12cfb71d54b01d85099b2/Objects/call.c#L557

@kumaraditya303 kumaraditya303 added the type-bug An unexpected behavior, bug, or error label May 25, 2022
@erlend-aasland erlend-aasland added the build The build process and cross-build label May 25, 2022
@vstinner
Copy link
Member

Do you want to propose a PR for that?

@kumaraditya303
Copy link
Contributor Author

Created PR #93215

@erlend-aasland
Copy link
Contributor

[...] most compilers supports this nowadays

As pointed out in cython/cython#4820, this may change in the future:

https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2975.pdf

@h-vetinari
Copy link
Contributor

h-vetinari commented Nov 7, 2022

As pointed out in cython/cython#4820, this may change in the future:

https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2975.pdf

Bit late, but JFYI, this paper got accepted into C23.

Edit: sorry for the double-post; GH bugging with server errors here...

arkamar added a commit to arkamar/immutables that referenced this issue May 29, 2023
The HAVE_STDARG_PROTOTYPES macro was removed in Python 3.12 [1,2] and
va_start with two arguments is always expected. Therefore, Python
version is newly checked as well and va_start with 2 arguments is
selected for python version greater or equal to 3.12.

[1] python/cpython@cb04a09
[2] python/cpython#93207
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.12 only security fixes build The build process and cross-build type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants