Commit ef4cff2
authored
Rollup merge of #153015 - joboet:atomic_alias_generic, r=jhpratt
core: make atomic primitives type aliases of `Atomic<T>`
Tracking issue: #130539
This makes `AtomicI32` and friends type aliases of `Atomic<T>` by encoding their alignment requirements via the use of an internal `Storage` associated type. This is also used to encode that `AtomicBool` store a `u8` internally.
Modulo the `Send`/`Sync` implementations, this PR does not move any trait implementations, methods or associated functions – I'll leave that for another PR.File tree
27 files changed
+315
-330
lines changed- compiler
- rustc_data_structures/src
- rustc_lint/src
- rustc_span/src
- library/core/src/sync
- src
- etc
- natvis
- tools/clippy
- clippy_lints/src/loops
- tests/ui
- tests
- debuginfo
- rustdoc-html
- jump-to-def
- reexport
- ui
- borrowck
- consts
- miri_unleashed
- lint
- resolve
- static
- stdlib-unit-tests
- suggestions
- sync
27 files changed
+315
-330
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | | - | |
64 | | - | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
65 | 67 | | |
66 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
67 | 72 | | |
68 | 73 | | |
69 | 74 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1036 | 1036 | | |
1037 | 1037 | | |
1038 | 1038 | | |
1039 | | - | |
1040 | | - | |
1041 | | - | |
1042 | | - | |
1043 | | - | |
1044 | | - | |
1045 | | - | |
1046 | | - | |
1047 | | - | |
1048 | | - | |
1049 | | - | |
1050 | | - | |
1051 | | - | |
1052 | | - | |
1053 | | - | |
1054 | | - | |
1055 | 1039 | | |
1056 | 1040 | | |
1057 | 1041 | | |
1058 | 1042 | | |
1059 | 1043 | | |
1060 | 1044 | | |
1061 | | - | |
1062 | | - | |
1063 | | - | |
| 1045 | + | |
1064 | 1046 | | |
1065 | 1047 | | |
1066 | 1048 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
| 174 | + | |
188 | 175 | | |
189 | 176 | | |
190 | 177 | | |
| |||
485 | 472 | | |
486 | 473 | | |
487 | 474 | | |
488 | | - | |
489 | 475 | | |
490 | 476 | | |
491 | 477 | | |
| |||
0 commit comments