https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107871

--- Comment #5 from 康桓瑋 <hewillk at gmail dot com> ---
(In reply to Jonathan Wakely from comment #4)
> Maybe you could legally do:
> 
> using difference_type = iterator_t<iota_view<__int128, __int128>>;
> 
> but maybe just don't do that. If things break when you do dumb things, don't
> do those things.

I would never do that.

However, I see that you seem to have considered this issue elsewhere, in
format#L2561:

            if constexpr (!is_integral_v<decltype(__n)>
                            || sizeof(__n) > sizeof(size_t))
              {
                // __int128 or __detail::__max_diff_type
                auto __m = (decltype(__n))(size_t)-1;
                if (__n > __m)
                  __n = __m;
              }

Reply via email to