diff options
| author | David Tolnay <dtolnay@gmail.com> | 2021-11-25 11:35:28 -0800 |
|---|---|---|
| committer | David Tolnay <dtolnay@gmail.com> | 2021-11-25 19:52:45 -0800 |
| commit | 2be9a8349f85f4cfcc4e26314bd5f165ef6d2b03 (patch) | |
| tree | 81277b6b4596887455a01aad52bd55de8e8d4fd0 /compiler/rustc_mir_transform/src/coverage/graph.rs | |
| parent | dd549dcab404ec4c7d07b5a83aca5bdd7171138f (diff) | |
| download | rust-2be9a8349f85f4cfcc4e26314bd5f165ef6d2b03.tar.gz rust-2be9a8349f85f4cfcc4e26314bd5f165ef6d2b03.zip | |
Eliminate bunch of copies of error codepath from Utf8LossyChunksIter
Using a macro to stamp out 7 identical copies of the nontrivial slicing logic to exit this loop didn't seem like a necessary use of a macro. The early return case can be handled by `break` without practically any changes to the logic inside the loop. All this code is from early 2014 (7.5 years old, pre-1.0) so it's possible there were compiler limitations that forced the macro way at the time. Confirmed that `x.py bench library/alloc --stage 0 --test-args from_utf8_lossy` is unaffected on my machine.
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/graph.rs')
0 files changed, 0 insertions, 0 deletions
