Re: coreutils and GCC -fanalyzer

2020-07-10 Thread Paul Eggert
On 7/10/20 2:21 PM, Pádraig Brady wrote: I'd be inclined to not enable -fanalyzer by default. At least not until it matures more. -fanalyzer didn't find any actual issues in coreutils, Yes, the only bug I found related to coreutils:

Re: coreutils and GCC -fanalyzer

2020-07-10 Thread Jeffrey Walton
On Fri, Jul 10, 2020 at 5:22 PM Pádraig Brady wrote: > > On 02/07/2020 01:26, Paul Eggert wrote: > > On 5/23/20 9:08 AM, Paul Eggert wrote: > > > >> So I am thinking of killing two > >> stones by doing the following. > >> > >> 1. Test for -fanalyzer, -Wall, -Wextra. > >> > >> 2. Test for flags

Re: coreutils and GCC -fanalyzer

2020-07-10 Thread Pádraig Brady
On 02/07/2020 01:26, Paul Eggert wrote: On 5/23/20 9:08 AM, Paul Eggert wrote: So I am thinking of killing two stones by doing the following. 1. Test for -fanalyzer, -Wall, -Wextra. 2. Test for flags not automatically enabled by -fanalyzer, -Wall, -Wextra but flags that we want anyway. 3.

Re: Callbacks in the abstact data types and extra contextual data

2020-07-10 Thread Bruno Haible
Marc Nieper-Wißkirchen wrote: > For GCC one can use nested functions, but how can > 'partial_function_last' be implemented in ISO C? It can be implemented for each CPU type and ABI. But this is OK since the number of CPU types are hardly increasing nowadays. It cannot be implemented in ISO C. >

Re: Callbacks in the abstact data types and extra contextual data

2020-07-10 Thread Marc Nieper-Wißkirchen
Hi Bruno, Am Fr., 10. Juli 2020 um 20:38 Uhr schrieb Bruno Haible : > OK. Then let's take the problem seriously. If your solution can be implemented portable, that will be the best solution by far. For GCC one can use nested functions, but how can 'partial_function_last' be implemented in ISO

Re: Callbacks in the abstact data types and extra contextual data

2020-07-10 Thread Bruno Haible
Hi Marc, > > > a number of modules (like the hash module or the list module) allow > > > the user to specify callbacks (e.g. a comparison function). > > > Unfortunately, these procedures do not take a context parameter, which > > > can be a problem because C lacks closures. > > > > Is this a

Re: portability issues with unicodeio

2020-07-10 Thread Bruno Haible
> * tests/test-unicodeio.c (main): In the "C" locale, expect either the > UTF-8 output or the specified fallback. Now that we have a unit test, I see that the test fails on NetBSD 9.0. This patch fixes it. 2020-07-10 Bruno Haible unicodeio: Fix wrong result on NetBSD.