Re: git: 05c9a0158f68 - main - libc: Add strverscmp(3) and versionsort(3)
- Reply: Jessica Clarke : "Re: git: 05c9a0158f68 - main - libc: Add strverscmp(3) and versionsort(3)"
- Reply: Brooks Davis : "Re: git: 05c9a0158f68 - main - libc: Add strverscmp(3) and versionsort(3)"
- In reply to: Jessica Clarke : "Re: git: 05c9a0158f68 - main - libc: Add strverscmp(3) and versionsort(3)"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 25 Aug 2022 01:22:56 UTC
On Thu, Aug 25, 2022 at 02:07:12AM +0100, Jessica Clarke wrote: > On 25 Aug 2022, at 01:29, Konstantin Belousov <kib@FreeBSD.org> wrote: > > + const unsigned char *u1 = __DECONST(const unsigned char *, s1); > > + const unsigned char *u2 = __DECONST(const unsigned char *, s2); > > Why is __DECONST needed? Casting from const char * to const unsigned > char * should never warn, surely? I requested the use of __DECONST there. Nobody knows what would be next trend in the C language breaking among compiler writers. We guarantee that __DECONST() is adopted to whatever warnings are added.