rust/tests/ui/pattern/usefulness/integer-ranges
Matthias Krüger e6ba504029
Rollup merge of #121908 - Nadrieril:dynamic-variant-collection, r=matthewjasper
match lowering: don't collect test alternatives ahead of time

I'm very happy with this one. Before this, when sorting candidates into the possible test branches, we manually computed `usize` indices to determine in which branch each candidate goes. To make this work we had a first pass that collected the possible alternatives we'd have to deal with, and a second pass that actually sorts the candidates.

In this PR, I replace `usize` indices with a dedicated enum. This makes `sort_candidates` easier to follow, and we don't need the first pass anymore.

r? ``@matthewjasper``
2024-03-13 06:41:21 +01:00
..
exhaustiveness.rs Allow lint where we don't care 2024-03-09 01:13:42 +01:00
exhaustiveness.stderr Allow lint where we don't care 2024-03-09 01:13:42 +01:00
gap_between_ranges.rs Lint small gaps between ranges 2024-03-09 01:14:22 +01:00
gap_between_ranges.stderr Lint small gaps between ranges 2024-03-09 01:14:22 +01:00
issue-117648-overlapping_range_endpoints-false-positive.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
overlapping_range_endpoints.rs Only lint ranges that really overlap 2024-01-11 14:04:11 +01:00
overlapping_range_endpoints.stderr Only lint ranges that really overlap 2024-01-11 14:04:11 +01:00
pointer-sized-int.deny.stderr Remove the precise_pointer_size_matching feature gate 2023-12-04 11:56:21 +01:00
pointer-sized-int.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
precise_pointer_matching-message.rs Match usize/isize exhaustively 2023-10-27 19:56:12 +02:00
precise_pointer_matching-message.stderr Remove the precise_pointer_size_matching feature gate 2023-12-04 11:56:21 +01:00
reachability.rs Allow lint where we don't care 2024-03-09 01:13:42 +01:00
reachability.stderr Allow lint where we don't care 2024-03-09 01:13:42 +01:00
regression-switchint-sorting-with-ranges.rs Fix a subtle regression 2024-03-02 18:38:37 +01:00