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

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
     Ever confirmed|0                           |1
           Assignee|unassigned at gcc dot gnu.org      |jason at gcc dot gnu.org
                 CC|                            |jason at gcc dot gnu.org,
                   |                            |jwakely.gcc at gmail dot com
   Last reconfirmed|                            |2020-05-26

--- Comment #1 from Jason Merrill <jason at gcc dot gnu.org> ---
Yes, in C++20 mode the < comparison uses operator<=> to produce a
std::strong_ordering, and then compares that to literal 0 to produce a boolean
value.  The operator< has an rhs type of 'std::__cmp_cat::__unspec', which has
a single constructor taking a pointer to itself, which is designed to only
accept null pointer constants, but this causes problems with this warning.

Reply via email to