Commit 359c88e
authored
Rollup merge of rust-lang#91439 - ecstatic-morse:const-cmp-trait-default-methods, r=oli-obk
Mark defaulted `PartialEq`/`PartialOrd` methods as const
WIthout it, `const` impls of these traits are unpleasant to write. I think this kind of change is allowed now. although it looks like it might require some Miri tweaks. Let's find out.
r? ```@fee1-dead```2 files changed
+38
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
218 | 219 | | |
219 | 220 | | |
220 | 221 | | |
| |||
1031 | 1032 | | |
1032 | 1033 | | |
1033 | 1034 | | |
| 1035 | + | |
1034 | 1036 | | |
1035 | 1037 | | |
1036 | 1038 | | |
| |||
1050 | 1052 | | |
1051 | 1053 | | |
1052 | 1054 | | |
| 1055 | + | |
1053 | 1056 | | |
1054 | 1057 | | |
1055 | 1058 | | |
| |||
1072 | 1075 | | |
1073 | 1076 | | |
1074 | 1077 | | |
| 1078 | + | |
1075 | 1079 | | |
1076 | 1080 | | |
1077 | 1081 | | |
| |||
1091 | 1095 | | |
1092 | 1096 | | |
1093 | 1097 | | |
| 1098 | + | |
1094 | 1099 | | |
1095 | 1100 | | |
1096 | 1101 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
203 | 203 | | |
204 | 204 | | |
205 | 205 | | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
0 commit comments