Skip to content

Commit 8d8a3d9

Browse files
authored
[CIR][NFC] Fix an unused variable warning (#138415)
This fixes a warning where a variable assigned in 'if' statement wasn't referenced again.
1 parent daf3236 commit 8d8a3d9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/lib/CIR/CodeGen/CIRGenExprConstant.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,9 +90,10 @@ class ConstExprEmitter
9090
}
9191

9292
mlir::Attribute VisitCastExpr(CastExpr *e, QualType destType) {
93-
if (const auto *ece = dyn_cast<ExplicitCastExpr>(e))
93+
if (isa<ExplicitCastExpr>(e))
9494
cgm.errorNYI(e->getBeginLoc(),
9595
"ConstExprEmitter::VisitCastExpr explicit cast");
96+
9697
Expr *subExpr = e->getSubExpr();
9798

9899
switch (e->getCastKind()) {

0 commit comments

Comments
 (0)