aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_def
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2020-07-31 20:58:36 +0100
committerAleksey Kladov <[email protected]>2020-07-31 21:04:12 +0100
commitb9c6aa9ec9e491160a6ad7c5ec66151bd67b0ecd (patch)
tree0ab0318ef1bd2bea1834fbe2ec0c899b5dd6189b /crates/ra_hir_def
parent675e86becfab2615528152487db49bce1b43bd60 (diff)
Unify naming of tuple fields
Diffstat (limited to 'crates/ra_hir_def')
-rw-r--r--crates/ra_hir_def/src/body/lower.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir_def/src/body/lower.rs b/crates/ra_hir_def/src/body/lower.rs
index 0d0365370..9d6562c38 100644
--- a/crates/ra_hir_def/src/body/lower.rs
+++ b/crates/ra_hir_def/src/body/lower.rs
@@ -496,7 +496,7 @@ impl ExprCollector<'_> {
496 self.alloc_expr(Expr::BinaryOp { lhs, rhs, op }, syntax_ptr) 496 self.alloc_expr(Expr::BinaryOp { lhs, rhs, op }, syntax_ptr)
497 } 497 }
498 ast::Expr::TupleExpr(e) => { 498 ast::Expr::TupleExpr(e) => {
499 let exprs = e.exprs().map(|expr| self.collect_expr(expr)).collect(); 499 let exprs = e.fields().map(|expr| self.collect_expr(expr)).collect();
500 self.alloc_expr(Expr::Tuple { exprs }, syntax_ptr) 500 self.alloc_expr(Expr::Tuple { exprs }, syntax_ptr)
501 } 501 }
502 ast::Expr::BoxExpr(e) => { 502 ast::Expr::BoxExpr(e) => {
@@ -762,7 +762,7 @@ impl ExprCollector<'_> {
762 } 762 }
763 ast::Pat::TupleStructPat(p) => { 763 ast::Pat::TupleStructPat(p) => {
764 let path = p.path().and_then(|path| self.expander.parse_path(path)); 764 let path = p.path().and_then(|path| self.expander.parse_path(path));
765 let (args, ellipsis) = self.collect_tuple_pat(p.args()); 765 let (args, ellipsis) = self.collect_tuple_pat(p.fields());
766 Pat::TupleStruct { path, args, ellipsis } 766 Pat::TupleStruct { path, args, ellipsis }
767 } 767 }
768 ast::Pat::RefPat(p) => { 768 ast::Pat::RefPat(p) => {
@@ -780,7 +780,7 @@ impl ExprCollector<'_> {
780 } 780 }
781 ast::Pat::ParenPat(p) => return self.collect_pat_opt(p.pat()), 781 ast::Pat::ParenPat(p) => return self.collect_pat_opt(p.pat()),
782 ast::Pat::TuplePat(p) => { 782 ast::Pat::TuplePat(p) => {
783 let (args, ellipsis) = self.collect_tuple_pat(p.args()); 783 let (args, ellipsis) = self.collect_tuple_pat(p.fields());
784 Pat::Tuple { args, ellipsis } 784 Pat::Tuple { args, ellipsis }
785 } 785 }
786 ast::Pat::WildcardPat(_) => Pat::Wild, 786 ast::Pat::WildcardPat(_) => Pat::Wild,