Rollup merge of #108958 - clubby789:unbox-the-hir, r=compiler-errors
Remove box expressions from HIR After #108516, `#[rustc_box]` is used at HIR->THIR lowering and this is no longer emitted, so it can be removed. This is based on top of #108471 to help with conflicts, so 43490488ccacd1a822e9c621f5ed6fca99959a0b is the only relevant commit (sorry for all the duplicated pings!) ````@rustbot```` label +S-blocked
This commit is contained in:
commit
13ff2d42cd
27 changed files with 12 additions and 73 deletions
|
@ -259,7 +259,6 @@ pub enum ExprPrecedence {
|
|||
Assign,
|
||||
AssignOp,
|
||||
|
||||
Box,
|
||||
AddrOf,
|
||||
Let,
|
||||
Unary,
|
||||
|
@ -319,8 +318,7 @@ impl ExprPrecedence {
|
|||
ExprPrecedence::AssignOp => AssocOp::Assign.precedence() as i8,
|
||||
|
||||
// Unary, prefix
|
||||
ExprPrecedence::Box
|
||||
| ExprPrecedence::AddrOf
|
||||
ExprPrecedence::AddrOf
|
||||
// Here `let pats = expr` has `let pats =` as a "unary" prefix of `expr`.
|
||||
// However, this is not exactly right. When `let _ = a` is the LHS of a binop we
|
||||
// need parens sometimes. E.g. we can print `(let _ = a) && b` as `let _ = a && b`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue