Commit ca79ead
committed
Make missing_const_for_fn operate on non-optimized MIR
This has two reasons: First of all we don't need the optimized MIR for
evaluating the checks of this lint, as const-eval anyways operates on
`mir_for_ctf` which is derived from `mir_drops_elaborated_and_const_checked`.
Second of all we might transform MIR in the optimization passes in a way
that doesn't work with const-eval, but it is irrelevant since const-eval
uses another MIR.
Specifically this came up when adding a new check in debug builds
(rust-lang/rust#134424), which is added as part
of an optimization pass.1 parent 25d319d commit ca79ead
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
157 | 157 | | |
158 | 158 | | |
159 | 159 | | |
160 | | - | |
| 160 | + | |
161 | 161 | | |
162 | | - | |
| 162 | + | |
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
| |||
0 commit comments