Add ast::ExprKind::Dummy

This commit is contained in:
Lieselotte 2024-02-25 22:22:09 +01:00
parent ce71137b96
commit 7d82dd0d31
2 changed files with 2 additions and 1 deletions

View File

@ -404,7 +404,7 @@ fn needs_space_after_range(rhs: &ast::Expr) -> bool {
// These do not occur in the AST because macros aren't expanded. // These do not occur in the AST because macros aren't expanded.
unreachable!() unreachable!()
} }
ast::ExprKind::Err => None, ast::ExprKind::Err | ast::ExprKind::Dummy => None,
}; };
expr_rw expr_rw

View File

@ -497,6 +497,7 @@ pub(crate) fn is_block_expr(context: &RewriteContext<'_>, expr: &ast::Expr, repr
| ast::ExprKind::Break(..) | ast::ExprKind::Break(..)
| ast::ExprKind::Cast(..) | ast::ExprKind::Cast(..)
| ast::ExprKind::Continue(..) | ast::ExprKind::Continue(..)
| ast::ExprKind::Dummy
| ast::ExprKind::Err | ast::ExprKind::Err
| ast::ExprKind::Field(..) | ast::ExprKind::Field(..)
| ast::ExprKind::IncludedBytes(..) | ast::ExprKind::IncludedBytes(..)