[all-commits] [llvm/llvm-project] 54d06f: [alpha.webkit.UncountedLocalVarsChecker] Don't ski...

Fady Farag via All-commits all-commits at lists.llvm.org
Tue Sep 29 21:48:33 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 54d06fb5c7ddce0c28e5bbb0d1a1eceea9870a9b
      https://github.com/llvm/llvm-project/commit/54d06fb5c7ddce0c28e5bbb0d1a1eceea9870a9b
  Author: Fady Farag <com.webkit.iidmsa at gmail.com>
  Date:   2026-09-29 (Tue, 29 Sep 2026)

  Changed paths:
    M clang/lib/StaticAnalyzer/Checkers/WebKit/RawPtrRefLocalVarsChecker.cpp
    M clang/test/Analysis/Checkers/WebKit/uncounted-local-vars.cpp

  Log Message:
  -----------
  [alpha.webkit.UncountedLocalVarsChecker] Don't skip the else branch of an if statement with a condition variable and a trivial then branch (#227262)

Previously, when an `if` statement had a condition variable and a
trivial then branch, `TraverseIfStmt` skipped the entire statement. That
is correct for the condition variable, which is null in the else branch,
but it also skipped the else branch, which caused a missing warning for
any raw pointer/reference local variable declared there. This still
exempts the condition variable but traverses the else branch when it is
not trivial.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list