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

--- Comment #6 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
(In reply to Giorgio Audrito from comment #5)
> I add that a very similar problem happens with -Wtype-limits, I found this
> minimal example:
> 
> template <unsigned x>
> struct foo {
>     bool bar(unsigned y) {
>         return y < x;
>     }
> };
> 
> int main() {
>     return foo<0>{}.bar(10);
> }
> 
> I don't know if that has been addressed as well (should it be a separate bug
> report?).

This is fixed on trunk and will be fixed in 10.3 too (I haven't backported the
patch to 10 yet.)

Reply via email to