================
@@ -431,6 +431,12 @@ class DeadStoreObs : public LiveVariables::Observer {
// bug.
if (isa<ParmVarDecl>(VD) && VD->getType()->isScalarType())
return;
+ // Special case: check for self-initializations.
+ //
+ // e.g. int x = x;
+ //
----------------
Snape3058 wrote:
https://github.com/llvm/llvm-project/blob/1d87171dc76bab8fd78e60deb9b239874c5fd83b/clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp#L417-L424
Just intended to make the format aligned with other comments nearby that have
an "e.g.".
https://github.com/llvm/llvm-project/pull/187530
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits