diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2025-02-18 11:24:57 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2025-02-18 12:52:56 +1100 |
| commit | a1daa34ad005d0b34d30c878cb4e2e995346d300 (patch) | |
| tree | bde73eb01e0197b4c9064ed7c9a0a01ba00a0c5e /compiler/rustc_mir_transform/src/patch.rs | |
| parent | ce36a966c79e109dabeef7a47fe68e5294c6d71e (diff) | |
| download | rust-a1daa34ad005d0b34d30c878cb4e2e995346d300.tar.gz rust-a1daa34ad005d0b34d30c878cb4e2e995346d300.zip | |
Use `MirPatch` in `EnumSizeOpt`.
Instead of `expand_statements`. This makes the code shorter and consistent with other MIR transform passes. The tests require updating because there is a slight change in MIR output: - the old code replaced the original statement with twelve new statements. - the new code inserts converts the original statement to a `nop` and then insert twelve new statements in front of it. I.e. we now end up with an extra `nop`, which doesn't matter at all.
Diffstat (limited to 'compiler/rustc_mir_transform/src/patch.rs')
0 files changed, 0 insertions, 0 deletions
