This repository was archived by the owner on May 28, 2025. It is now read-only.
Commit d226671
authored
Unrolled build for rust-lang#126932
Rollup merge of rust-lang#126932 - Zalathar:flat-pat, r=Nadrieril
Tweak `FlatPat::new` to avoid a temporarily-invalid state
It was somewhat confusing that the old constructor would create a `FlatPat` in a (possibly) non-simplified state, and then simplify its contents in-place.
So instead we now create its fields as local variables, perform simplification, and then create the struct afterwards.
This doesn't affect correctness, but is less confusing.
---
I've also included some semi-related comments that I made while trying to navigate this code.2 files changed
+24
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1031 | 1031 | | |
1032 | 1032 | | |
1033 | 1033 | | |
| 1034 | + | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
1034 | 1040 | | |
1035 | 1041 | | |
1036 | 1042 | | |
| |||
1042 | 1048 | | |
1043 | 1049 | | |
1044 | 1050 | | |
| 1051 | + | |
| 1052 | + | |
1045 | 1053 | | |
1046 | 1054 | | |
1047 | 1055 | | |
1048 | 1056 | | |
1049 | 1057 | | |
1050 | | - | |
1051 | | - | |
1052 | | - | |
1053 | | - | |
1054 | | - | |
1055 | | - | |
1056 | | - | |
1057 | | - | |
1058 | | - | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
| 1064 | + | |
1059 | 1065 | | |
1060 | | - | |
1061 | | - | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
| 1069 | + | |
1062 | 1070 | | |
1063 | 1071 | | |
1064 | 1072 | | |
| |||
1104 | 1112 | | |
1105 | 1113 | | |
1106 | 1114 | | |
| 1115 | + | |
| 1116 | + | |
1107 | 1117 | | |
1108 | 1118 | | |
1109 | 1119 | | |
| 1120 | + | |
1110 | 1121 | | |
1111 | 1122 | | |
1112 | 1123 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
95 | 95 | | |
96 | 96 | | |
97 | 97 | | |
| 98 | + | |
| 99 | + | |
98 | 100 | | |
99 | 101 | | |
100 | 102 | | |
| |||
0 commit comments