Commit 46424fb
committed
Auto merge of rust-lang#138206 - amy-kwan:amy-kwan/reprc-struct-power-align-ignore-packed-align, r=workingjubilee
[AIX] Ignore linting on repr(C) structs with repr(packed) or repr(align(n))
This PR updates the lint added in 9b40bd7 to ignore repr(C) structs that also have repr(packed) or repr(align(n)).
As these representations can be modifiers on repr(C), it is assumed that users that add these should know what they are doing, and thus the the lint should not warn on the respective structs. For example, for the time being, using repr(packed) and manually padding a repr(C) struct can be done to correctly align struct members on AIX.File tree
2 files changed
+31
-1
lines changed- compiler/rustc_lint/src
- tests/ui/layout
2 files changed
+31
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1634 | 1634 | | |
1635 | 1635 | | |
1636 | 1636 | | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
1637 | 1640 | | |
1638 | 1641 | | |
1639 | 1642 | | |
| |||
1655 | 1658 | | |
1656 | 1659 | | |
1657 | 1660 | | |
| 1661 | + | |
| 1662 | + | |
1658 | 1663 | | |
1659 | 1664 | | |
| 1665 | + | |
1660 | 1666 | | |
1661 | 1667 | | |
1662 | 1668 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
148 | 148 | | |
149 | 149 | | |
150 | 150 | | |
151 | | - | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
152 | 176 | | |
0 commit comments