Skip to content

Commit 15f2423

Browse files
committed
Remove box_syntax from AST and use in tools
1 parent 213a22e commit 15f2423

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

clippy_lints/src/suspicious_operation_groupings.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -596,8 +596,7 @@ fn ident_difference_expr_with_base_location(
596596
| (MethodCall(_), MethodCall(_))
597597
| (Call(_, _), Call(_, _))
598598
| (ConstBlock(_), ConstBlock(_))
599-
| (Array(_), Array(_))
600-
| (Box(_), Box(_)) => {
599+
| (Array(_), Array(_)) => {
601600
// keep going
602601
},
603602
_ => {

clippy_utils/src/ast_utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ pub fn eq_expr(l: &Expr, r: &Expr) -> bool {
143143
(Paren(l), _) => eq_expr(l, r),
144144
(_, Paren(r)) => eq_expr(l, r),
145145
(Err, Err) => true,
146-
(Box(l), Box(r)) | (Try(l), Try(r)) | (Await(l), Await(r)) => eq_expr(l, r),
146+
(Try(l), Try(r)) | (Await(l), Await(r)) => eq_expr(l, r),
147147
(Array(l), Array(r)) => over(l, r, |l, r| eq_expr(l, r)),
148148
(Tup(l), Tup(r)) => over(l, r, |l, r| eq_expr(l, r)),
149149
(Repeat(le, ls), Repeat(re, rs)) => eq_expr(le, re) && eq_expr(&ls.value, &rs.value),

clippy_utils/src/sugg.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,6 @@ impl<'a> Sugg<'a> {
188188
match expr.kind {
189189
_ if expr.span.ctxt() != ctxt => Sugg::NonParen(snippet_with_context(cx, expr.span, ctxt, default, app).0),
190190
ast::ExprKind::AddrOf(..)
191-
| ast::ExprKind::Box(..)
192191
| ast::ExprKind::Closure { .. }
193192
| ast::ExprKind::If(..)
194193
| ast::ExprKind::Let(..)

0 commit comments

Comments
 (0)