Re: [PATCH] gimple-ssa-sprintf: Use [0, 1] range for %lc with (wint_t) 0 argument [PR114876]

2024-04-30 Thread Richard Biener
On Tue, 30 Apr 2024, Jakub Jelinek wrote: > Hi! > > Seems when Martin S. implemented this, he coded there strict reading > of the standard, which said that %lc with (wint_t) 0 argument is handled > as wchar_t[2] temp = { arg, 0 }; %ls with temp arg and so shouldn't print > any values. But, most

[PATCH] gimple-ssa-sprintf: Use [0, 1] range for %lc with (wint_t) 0 argument [PR114876]

2024-04-30 Thread Jakub Jelinek
Hi! Seems when Martin S. implemented this, he coded there strict reading of the standard, which said that %lc with (wint_t) 0 argument is handled as wchar_t[2] temp = { arg, 0 }; %ls with temp arg and so shouldn't print any values. But, most of the libc implementations actually handled that case