Skip to content

Commit 4d73300

Browse files
authored
Rollup merge of #86381 - yerke:add-test-for-issue-39161, r=JohnTitor
Add regression test for issue #39161 Closes #39161 Based on feedback from ``@JohnTitor`` in #71333 r? ``@JohnTitor``
2 parents 8389cd3 + 503abc7 commit 4d73300

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// check-pass
2+
3+
pub struct X {
4+
pub a: i32,
5+
pub b: i32,
6+
}
7+
8+
fn main() {
9+
const DX: X = X { a: 0, b: 0 };
10+
const _X1: X = X { a: 1, ..DX };
11+
let _x2 = X { a: 1, b: 2, ..DX };
12+
const _X3: X = X { a: 1, b: 2, ..DX };
13+
}

0 commit comments

Comments
 (0)