Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-15 Thread Bruno Haible via Gnulib discussion list
Alejandro Colomar wrote: > > * gperf generated code has these warnings: > > unicase/special-casing-table.gperf:171:10: warning: zero as null > > pointer constant [-Wzero-as-null-pointer-constant] > > unictype/categ_byname.gperf:115:10: warning: zero as null pointer > > constant [-Wzero-

Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-14 Thread Simon Josefsson via Gnulib discussion list
Bruno Haible via Gnulib discussion list writes: > I promised: >> - see how this new warning behaves on the Gnulib source code > > The two good news are: > - The warning is really helpful. With it, I could find all relevant uses of > '0' quickly. Patch attached and committed. > - There w

Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-14 Thread Alejandro Colomar
Hi Bruno, On Thu, Nov 14, 2024 at 04:14:26PM GMT, Bruno Haible wrote: > I promised: > > - see how this new warning behaves on the Gnulib source code Thanks! > The two good news are: > - The warning is really helpful. With it, I could find all relevant uses of > '0' quickly. Patch attache

Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-14 Thread Bruno Haible via Gnulib discussion list
I promised: > - see how this new warning behaves on the Gnulib source code The two good news are: - The warning is really helpful. With it, I could find all relevant uses of '0' quickly. Patch attached and committed. - There were no false positives. However, there are warnings that are

Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-14 Thread Simon Josefsson via Gnulib discussion list
Bruno Haible via Gnulib discussion list writes: > Hi Alejandro, > >> We're planning a path for deprecation of 0 as a null pointer constant, >> in favor of NULL > > +1 +1 > For reference, we discussed the use of nullptr in Gnulib [1][2] in the past. > >> As a first step, Joseph proposed adding i

Re: gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-13 Thread Bruno Haible via Gnulib discussion list
Hi Alejandro, > We're planning a path for deprecation of 0 as a null pointer constant, > in favor of NULL +1 For reference, we discussed the use of nullptr in Gnulib [1][2] in the past. > As a first step, Joseph proposed adding it into gnulib's manywarnings. > Does it sound good to you? Yes. U

gnulib-manywarnings: Enable -Wzero-as-null-pointer-constant

2024-11-13 Thread Alejandro Colomar
Hi Bruno, Link: Link: GCC 15 has added -Wzero-as-null-pointer-constant for C (or actually, will, once it's released). We're planning a path for deprecation of 0 as a null point