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

            Bug ID: 124217
           Summary: RFE: new -Wanalyzer-div-by-zero warning
           Product: gcc
           Version: 16.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: analyzer
          Assignee: dmalcolm at gcc dot gnu.org
          Reporter: dmalcolm at gcc dot gnu.org
        Depends on: 124195
  Target Milestone: ---

Fixing bug 124195 requires detecting division by zero in the analyzer.

I have a fix for this, and in theory it would be easy to issue a warning on
such code paths.  However, it seems too late to be adding a new warning to GCC
16, so filing this RFE as a reminder to add the warning in GCC 17.

We already have -Wdiv-by-zero, so -Wanalyzer-div-by-zero is probably best for
the new warning.


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124195
[Bug 124195] [16 Regression] ICE: in type, at value-range.h:1004 with
-fanalyzer and division by zero

Reply via email to