Skip to content

Commit fb0fbad

Browse files
committed
Rename variable name in question_mark
1 parent 2fd1682 commit fb0fbad

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

clippy_lints/src/question_mark.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -172,17 +172,17 @@ impl QuestionMark {
172172
}
173173
}
174174

175-
fn expression_returns_unmodified_err(cx: &LateContext<'_>, expression: &Expr<'_>, cond_expr: &Expr<'_>) -> bool {
176-
match expression.kind {
175+
fn expression_returns_unmodified_err(cx: &LateContext<'_>, expr: &Expr<'_>, cond_expr: &Expr<'_>) -> bool {
176+
match expr.kind {
177177
ExprKind::Block(block, _) => {
178178
if let Some(return_expression) = Self::return_expression(block) {
179179
return Self::expression_returns_unmodified_err(cx, return_expression, cond_expr);
180180
}
181181

182182
false
183183
},
184-
ExprKind::Ret(Some(expr)) => Self::expression_returns_unmodified_err(cx, expr, cond_expr),
185-
ExprKind::Path(_) => path_to_local(expression) == path_to_local(cond_expr),
184+
ExprKind::Ret(Some(ret_expr)) => Self::expression_returns_unmodified_err(cx, ret_expr, cond_expr),
185+
ExprKind::Path(_) => path_to_local(expr) == path_to_local(cond_expr),
186186
_ => false,
187187
}
188188
}

0 commit comments

Comments
 (0)