On Wed, 24 Jul 2024 at 11:38, Dennis Luehring via Gcc <gcc@gcc.gnu.org> wrote:
>
> using latest gcc/STL
>
> ---------
> #include <set>
>
> using int_set1 = std::set<int, std::greater<int>>;
> using int_set2 = std::set<int>;
>
> static_assert(std::is_same<int_set1::iterator, int_set2::iterator>());
> ---------
>
>
> the two iterators are equal when not using _GLIBCXX_DEBUG but become
> different when using the define?

Your question belongs on either the libstdc++ or gcc-help mailing
list, not here. This list is for discussing development of GCC itself,
not help using it.

The standard says it's unspecified whether those types are the same,
so portable code should not assume they are/aren't the same. I don't
know for sure, but I assume somebody thought that making them
different was helpful to avoid non-portable code.

Reply via email to