steakhal requested changes to this revision.
steakhal added a comment.
This revision now requires changes to proceed.

Shadowing potential names is not a good idea.
BTW OpCodes are often abbreviated to `Op` in variable names in this context.



================
Comment at: clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp:110-111
       break;
-    if (BO->getOpcode() == BO_Assign) {
-      Ex = BO->getRHS();
-      continue;
-    }
-    if (BO->getOpcode() == BO_Comma) {
+    BinaryOperatorKind BO_AssignOrComma = BO->getOpcode();
+    if (BO_AssignOrComma == BO_Assign || BO_AssignOrComma == BO_Comma) {
       Ex = BO->getRHS();
----------------



Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D121045/new/

https://reviews.llvm.org/D121045

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to