[clang] [analyzer] Add optin.taint.TaintedDiv checker (PR #106389)

DonĂ¡t Nagy via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 30 04:57:52 PDT 2024


================
@@ -25,16 +25,20 @@ using namespace ento;
 using namespace taint;
 
 namespace {
-class DivZeroChecker : public Checker< check::PreStmt<BinaryOperator> > {
-  const BugType BT{this, "Division by zero"};
-  const BugType TaintBT{this, "Division by zero", categories::TaintedData};
+class DivZeroChecker : public Checker<check::PreStmt<BinaryOperator>> {
   void reportBug(StringRef Msg, ProgramStateRef StateZero,
                  CheckerContext &C) const;
   void reportTaintBug(StringRef Msg, ProgramStateRef StateZero,
                       CheckerContext &C,
                       llvm::ArrayRef<SymbolRef> TaintedSyms) const;
 
 public:
+  /// This checker class implements multiple user facing checker
----------------
NagyDonat wrote:

```suggestion
  /// This checker class implements several user facing checkers
```

https://github.com/llvm/llvm-project/pull/106389


More information about the cfe-commits mailing list