http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56497



             Bug #: 56497

           Summary: comparison is always true due to limited range of data

                    type

    Classification: Unclassified

           Product: gcc

           Version: unknown

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: c++

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: mathieu.malate...@gmail.com





Created attachment 29563

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29563

g++ -Wtype-limits test.cxx



It would be really nice if -Wtype-limits would catch all occurences in the

following test case.



Steps:



$ g++ -Wtype-limits test.cxx

test.cxx: In function 'int main()':

test.cxx:25:33: warning: comparison is always true due to limited range of data

type [-Wtype-limits]

Reply via email to