Skip to content

Commit

Permalink
Remove LLVM-style inline assembly from rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
tmiasko committed Jan 12, 2022
1 parent d60edea commit d4fb6ec
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
4 changes: 1 addition & 3 deletions src/tools/rustfmt/src/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -334,9 +334,7 @@ pub(crate) fn format_expr(
// satisfy our width restrictions.
// Style Guide RFC for InlineAsm variant pending
// https://github.com/rust-dev-tools/fmt-rfcs/issues/152
ast::ExprKind::LlvmInlineAsm(..) | ast::ExprKind::InlineAsm(..) => {
Some(context.snippet(expr.span).to_owned())
}
ast::ExprKind::InlineAsm(..) => Some(context.snippet(expr.span).to_owned()),
ast::ExprKind::TryBlock(ref block) => {
if let rw @ Some(_) =
rewrite_single_line_block(context, "try ", block, Some(&expr.attrs), None, shape)
Expand Down
1 change: 0 additions & 1 deletion src/tools/rustfmt/src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,6 @@ pub(crate) fn is_block_expr(context: &RewriteContext<'_>, expr: &ast::Expr, repr
| ast::ExprKind::Err
| ast::ExprKind::Field(..)
| ast::ExprKind::InlineAsm(..)
| ast::ExprKind::LlvmInlineAsm(..)
| ast::ExprKind::Let(..)
| ast::ExprKind::Path(..)
| ast::ExprKind::Range(..)
Expand Down

0 comments on commit d4fb6ec

Please sign in to comment.