Skip to content

Commit 2f25a4a

Browse files
committed
Fix double space in pretty printed TryBlock
1 parent 2b67c30 commit 2f25a4a

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

compiler/rustc_ast_pretty/src/pprust/state.rs

-1
Original file line numberDiff line numberDiff line change
@@ -2239,7 +2239,6 @@ impl<'a> State<'a> {
22392239
}
22402240
ast::ExprKind::TryBlock(ref blk) => {
22412241
self.head("try");
2242-
self.space();
22432242
self.print_block_with_attrs(blk, attrs)
22442243
}
22452244
ast::ExprKind::Err => {

src/test/ui/macros/stringify.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ fn test_expr() {
256256
assert_eq!(stringify_expr!(expr.await), "expr.await");
257257

258258
// ExprKind::TryBlock
259-
assert_eq!(stringify_expr!(try {}), "try {}"); // FIXME
259+
assert_eq!(stringify_expr!(try {}), "try {}");
260260

261261
// ExprKind::Assign
262262
assert_eq!(stringify_expr!(expr = true), "expr = true");

0 commit comments

Comments
 (0)