Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-21 Thread Jonathan Wakely
On Wed, 20 Mar 2024 at 18:11, François Dumont wrote: > > As proposed below I also updated gcc-13 branch. Great, thanks. > > libstdc++: [_GLIBCXX_DEBUG] Define __cpp_lib_null_iterators > > _GLIBCXX_DEBUG has now fully N3344 compliant iterator checks, we > can define >

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-20 Thread François Dumont
As proposed below I also updated gcc-13 branch.     libstdc++: [_GLIBCXX_DEBUG] Define __cpp_lib_null_iterators     _GLIBCXX_DEBUG has now fully N3344 compliant iterator checks, we can define     __cpp_lib_null_iterators macros like the normal mode.     libstdc++-v3/ChangeLog:     *

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-20 Thread Jonathan Wakely
On Wed, 20 Mar 2024 at 05:59, François Dumont wrote: > > Thanks to you doc: > > libstdc++: [_GLIBCXX_DEBUG] Define __[glibcxx,cpp_lib]_null_iterators > > _GLIBCXX_DEBUG has now fully N3344 compliant iterator checks, we > can define > __glibcxx_null_iterators and

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-19 Thread François Dumont
Thanks to you doc:     libstdc++: [_GLIBCXX_DEBUG] Define __[glibcxx,cpp_lib]_null_iterators     _GLIBCXX_DEBUG has now fully N3344 compliant iterator checks, we can define     __glibcxx_null_iterators and __cpp_lib_null_iterators macros like the normal     mode.     libstdc++-v3/ChangeLog:

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-19 Thread Jonathan Wakely
On Tue, 19 Mar 2024 at 09:31, Jonathan Wakely wrote: > > On Mon, 18 Mar 2024 at 21:38, François Dumont wrote: > > > > Both committed now. > > > > Just to confirm, those 2 last patches should be backported to gcc-13 > > branch, right ? > > Yes please. > > > > > I might have a try to update

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-19 Thread Jonathan Wakely
On Mon, 18 Mar 2024 at 21:38, François Dumont wrote: > > Both committed now. > > Just to confirm, those 2 last patches should be backported to gcc-13 > branch, right ? Yes please. > > I might have a try to update version.h but if you want to do it before > don't hesitate. You'll need to have

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-18 Thread François Dumont
Both committed now. Just to confirm, those 2 last patches should be backported to gcc-13 branch, right ? I might have a try to update version.h but if you want to do it before don't hesitate. François On 18/03/2024 08:45, Jonathan Wakely wrote: On Sun, 17 Mar 2024 at 18:14, François

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-18 Thread Jonathan Wakely
On Sun, 17 Mar 2024 at 16:52, François Dumont wrote: > > > > > > OK for trunk, thanks! > > > > I think this is OK to backport to 13 too. > > > > Maybe after this we can define the __cpp_lib_null_itetators macro for > > debug mode? > > > After this fix of local_iterator I think we can indeed. > >

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-18 Thread Jonathan Wakely
On Sun, 17 Mar 2024 at 18:14, François Dumont wrote: > > I was a little bit too confident below. After review of all _M_singular > usages I found another necessary fix. > > After this one for sure we will be able to define > __cpp_lib_null_iterators even in Debug mode. > > libstdc++: Fix

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-17 Thread François Dumont
I was a little bit too confident below. After review of all _M_singular usages I found another necessary fix. After this one for sure we will be able to define __cpp_lib_null_iterators even in Debug mode.     libstdc++: Fix N3344 behavior on _Safe_iterator::_M_can_advance     We shall be

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-17 Thread François Dumont
OK for trunk, thanks! I think this is OK to backport to 13 too. Maybe after this we can define the __cpp_lib_null_itetators macro for debug mode? After this fix of local_iterator I think we can indeed. In fact the added 11316.cc was already passing for unordered_set<>::local_iterator

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-17 Thread Jonathan Wakely
On Sat, 16 Mar 2024, 12:16 François Dumont, wrote: > With the patch, sorry. > > On 14/03/2024 22:49, François Dumont wrote: > > Hi > > > > This is what I started to do. > > > > For now I haven't touch to __cpp_lib_null_iterators definition as > > _Safe_local_iterator still need some work. > > >

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-16 Thread François Dumont
With the patch, sorry. On 14/03/2024 22:49, François Dumont wrote: Hi This is what I started to do. For now I haven't touch to __cpp_lib_null_iterators definition as _Safe_local_iterator still need some work. libstdc++: Implement N3644 on _Safe_iterator<> [PR114316] Consider range of

Re: _LIBCXX_DEBUG value initialized singular iterators assert failures in std algorithms [PR104316]

2024-03-14 Thread François Dumont
Hi This is what I started to do. For now I haven't touch to __cpp_lib_null_iterators definition as _Safe_local_iterator still need some work. libstdc++: Implement N3644 on _Safe_iterator<> [PR114316] Consider range of value-initialized iterators as valid and empty. libstdc++-v3/ChangeLog: