[clang-tools-extra] [clang-tidy][NFC] Apply llvm-redundant-casting check (PR #214024)
Yanzuo Liu via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 4 18:50:11 PDT 2026
================
@@ -91,7 +91,7 @@ static bool isVarPossiblyChanged(const Decl *Func, const Stmt *LoopStmt,
static bool isVarThatIsPossiblyChanged(const Decl *Func, const Stmt *LoopStmt,
const Stmt *Cond, ASTContext *Context) {
if (const auto *DRE = dyn_cast<DeclRefExpr>(Cond)) {
- if (const auto *VD = dyn_cast<ValueDecl>(DRE->getDecl()))
+ if (const auto *VD = DRE->getDecl())
----------------
zwuis wrote:
```suggestion
if (const ValueDecl *VD = DRE->getDecl())
```
https://github.com/llvm/llvm-project/pull/214024
More information about the cfe-commits
mailing list