Commit c81e751
committed
Skip redundant frames in const recursion errors
```
error[E0080]: evaluation of constant value failed
--> $DIR/infinite-recursion-const-fn.rs:4:5
|
LL | b()
| ^^^ reached the configured maximum number of stack frames
|
note: inside `a`
--> $DIR/infinite-recursion-const-fn.rs:4:5
|
LL | b()
| ^^^
note: inside `b`
--> $DIR/infinite-recursion-const-fn.rs:7:5
|
LL | a()
| ^^^
note: [... 125 additional calls ...] inside `b`
--> $DIR/infinite-recursion-const-fn.rs:7:5
|
LL | a()
| ^^^
note: inside `ARR::{constant#0}`
--> $DIR/infinite-recursion-const-fn.rs:9:18
|
LL | const ARR: [i32; a()] = [5; 6];
| ^^^
```1 parent 8231065 commit c81e751
File tree
7 files changed
+16
-1252
lines changed- compiler/rustc_const_eval
- src
- const_eval
- tests/ui
- consts
- explicit-tail-calls
- infinite
7 files changed
+16
-1252
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
120 | | - | |
| 120 | + | |
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
12 | | - | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| |||
93 | 94 | | |
94 | 95 | | |
95 | 96 | | |
96 | | - | |
| 97 | + | |
97 | 98 | | |
98 | 99 | | |
99 | 100 | | |
| |||
104 | 105 | | |
105 | 106 | | |
106 | 107 | | |
107 | | - | |
108 | | - | |
| 108 | + | |
| 109 | + | |
109 | 110 | | |
110 | 111 | | |
111 | 112 | | |
| |||
116 | 117 | | |
117 | 118 | | |
118 | 119 | | |
119 | | - | |
| 120 | + | |
| 121 | + | |
120 | 122 | | |
121 | 123 | | |
122 | 124 | | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
| 125 | + | |
128 | 126 | | |
129 | 127 | | |
130 | 128 | | |
131 | 129 | | |
132 | 130 | | |
133 | 131 | | |
| 132 | + | |
134 | 133 | | |
135 | 134 | | |
136 | 135 | | |
| |||
219 | 218 | | |
220 | 219 | | |
221 | 220 | | |
222 | | - | |
| 221 | + | |
223 | 222 | | |
224 | 223 | | |
225 | 224 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
264 | 264 | | |
265 | 265 | | |
266 | 266 | | |
267 | | - | |
| 267 | + | |
268 | 268 | | |
269 | 269 | | |
270 | 270 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
| 18 | + | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| |||
0 commit comments