Skip to content

Commit 893e972

Browse files
committed
keep const blocks around
1 parent 2f9a893 commit 893e972

2 files changed

Lines changed: 17 additions & 0 deletions

File tree

tests/source/issue-6788.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
fn foo() {
2+
let a = [(); const { let x = 1; x }];
3+
}
4+
5+
fn foo() {
6+
let x = [(); const { 1 }];
7+
}

tests/target/issue-6788.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
fn foo() {
2+
let a = [(); const {
3+
let x = 1;
4+
x
5+
}];
6+
}
7+
8+
fn foo() {
9+
let x = [(); const { 1 }];
10+
}

0 commit comments

Comments
 (0)