Skip to content

Commit 7d012e8

Browse files
committed
Add rustfmt test from rust-lang#117942
1 parent 0c0df4e commit 7d012e8

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

src/tools/rustfmt/tests/target/anonymous-types.rs

+12
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,16 @@ struct Foo {
1616
e: f32,
1717
}
1818

19+
// Test for https://github.com/rust-lang/rust/issues/117942
20+
struct Foo {
21+
_: union {
22+
#[rustfmt::skip]
23+
f: String,
24+
},
25+
#[rustfmt::skip]
26+
_: struct {
27+
g: i32,
28+
},
29+
}
30+
1931
fn main() {}

0 commit comments

Comments
 (0)