-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #85515 - jedel1043:fix-85480, r=petrochenkov
Fix ast pretty printing for anonymous types Fixes #85480.
- Loading branch information
Showing
2 changed files
with
30 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// Test for issue 85480 | ||
// Pretty print anonymous struct and union types | ||
|
||
// pp-exact | ||
// pretty-compare-only | ||
|
||
struct Foo { | ||
_: union { | ||
_: struct { | ||
a: u8, | ||
b: u16, | ||
}, | ||
c: u32, | ||
}, | ||
d: u64, | ||
e: f32, | ||
} | ||
|
||
type A = | ||
struct { | ||
field: u8, | ||
}; | ||
|
||
fn main() { } |