Skip to content

Comments

fix initialization discards 'const' qualifier from pointer target type#783

Open
heitbaum wants to merge 1 commit intovmware:masterfrom
heitbaum:glibc-2.43
Open

fix initialization discards 'const' qualifier from pointer target type#783
heitbaum wants to merge 1 commit intovmware:masterfrom
heitbaum:glibc-2.43

Conversation

@heitbaum
Copy link

Since glibc-2.43:

For ISO C23, the functions bsearch, memchr, strchr, strpbrk, strrchr, strstr, wcschr, wcspbrk, wcsrchr, wcsstr and wmemchr that return pointers into their input arrays now have definitions as macros that return a pointer to a const-qualified type when the input argument is a pointer to a const-qualified type.

https://lists.gnu.org/archive/html/info-gnu/2026-01/msg00005.html

Since glibc-2.43:

For ISO C23, the functions bsearch, memchr, strchr, strpbrk, strrchr,
strstr, wcschr, wcspbrk, wcsrchr, wcsstr and wmemchr that return
pointers into their input arrays now have definitions as macros that
return a pointer to a const-qualified type when the input argument is
a pointer to a const-qualified type.

https://lists.gnu.org/archive/html/info-gnu/2026-01/msg00005.html

Signed-off-by: Rudi Heitbaum <rudi@heitbaum.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build against glibc-2.43 fails due to -Werror=discarded-qualifiers

1 participant