mirror of
https://github.com/rust-lang/rust.git
synced 2026-06-03 01:16:14 +03:00
Exhaustively enumerate expressions in expression rewriting.
This commit is contained in:
+9
-1
@@ -155,7 +155,15 @@ fn rewrite(&self, context: &RewriteContext, width: usize, offset: Indent) -> Opt
|
||||
}
|
||||
// We do not format these expressions yet, but they should still
|
||||
// satisfy our width restrictions.
|
||||
_ => wrap_str(context.snippet(self.span), context.config.max_width, width, offset),
|
||||
ast::Expr_::ExprBox(..) |
|
||||
ast::Expr_::ExprCast(..) |
|
||||
ast::Expr_::ExprIndex(..) |
|
||||
ast::Expr_::ExprAddrOf(..) |
|
||||
ast::Expr_::ExprRet(..) |
|
||||
ast::Expr_::ExprInlineAsm(..) |
|
||||
ast::Expr_::ExprRepeat(..) => {
|
||||
wrap_str(context.snippet(self.span), context.config.max_width, width, offset)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user