https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83591
Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2017-12-26
                 CC|                            |manu at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #3 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
> cc1plus: error: this condition has identical branches

This suggests that GCC has somehow lost the source location info for this
warning (even the file location), so GCC does not know that it happens inside a
system header nor it can be silenced with #pragmas, since those rely on the
location.

> I suspect this is related to
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82541 but it has differences:

I think PR82541 is asking that cond ? A : B is not warned about if A and B are
textually different, even if they are template parameters that expand to the
same expression.

In your case, the warning is correct, but the location is broken, so the
location-based tricks to silence it do not work.

Reply via email to