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

Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |manu at gcc dot gnu.org

--- Comment #1 from Manuel López-Ibáñez <manu at gcc dot gnu.org> 2013-03-01 
17:20:38 UTC ---
(In reply to comment #0)
> Created attachment 29563 [details]
> g++ -Wtype-limits test.cxx
> 
> It would be really nice if -Wtype-limits would catch all occurences in the
> following test case.

That seems nearly impossible. The warning is emitted in the FE, and this would
require inlining and/or constant propagation into function calls. Not likely to
ever happen in GCC. You need something like http://clang-analyzer.llvm.org/ or
http://cppcheck.sourceforge.net/. Better report a bug to them.

Reply via email to