Unnamed repository; edit this file 'description' to name the repository.
-rw-r--r--crates/hir-def/src/body/lower.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/crates/hir-def/src/body/lower.rs b/crates/hir-def/src/body/lower.rs
index 37a0940a3f..111460d1a6 100644
--- a/crates/hir-def/src/body/lower.rs
+++ b/crates/hir-def/src/body/lower.rs
@@ -80,8 +80,7 @@ pub(super) fn lower(
params: Option<ast::ParamList>,
body: Option<ast::Expr>,
) -> (Body, BodySourceMap) {
- let collector = ExprCollector::new(db, expander);
- collector.collect(params, body)
+ ExprCollector::new(db, expander).collect(params, body)
}
struct ExprCollector<'a> {
@@ -190,8 +189,7 @@ impl<'a> ExprCollector<'a> {
}
fn collect_expr(&mut self, expr: ast::Expr) -> ExprId {
- let expr_id = self.maybe_collect_expr(expr).unwrap_or_else(|| self.missing_expr());
- expr_id
+ self.maybe_collect_expr(expr).unwrap_or_else(|| self.missing_expr())
}
/// Returns `None` if and only if the expression is `#[cfg]`d out.