summary refs log tree commit diff
path: root/tests/ui/pattern
AgeCommit message (Collapse)AuthorLines
2023-05-25Add NOTE annotations.Camille GILLOT-75/+141
2023-05-25Add inter-crate test.Camille GILLOT-40/+75
2023-05-21Rename `drop_ref` lint to `dropping_references`Urgau-3/+3
2023-05-21Rename `drop_copy` lint to `dropping_copy_types`Urgau-2/+2
2023-05-16Auto merge of #105750 - oli-obk:valtrees, r=lcnrbors-40/+53
Always fall back to PartialEq when a constant in a pattern is not recursively structural-eq Right now we destructure the constant as far as we can, but with this PR we just don't take it apart anymore. This is preparatory work for moving to always using valtrees, as these will just do a single conversion of the constant to a valtree at the start, and if that fails, fall back to `PartialEq`. This removes a few cases where we emitted the `unreachable pattern` lint, because we stop looking into the constant deeply enough to detect that a constant is already covered by another pattern. Previous work: https://github.com/rust-lang/rust/pull/70743 This is groundwork towards fixing https://github.com/rust-lang/rust/issues/83085 and https://github.com/rust-lang/rust/issues/105047
2023-05-16Rollup merge of #111428 - bvanjoi:fix-109250, r=NilstriebNilstrieb-6/+9
refactor(resolve): clean up the early error return caused by non-call closes https://github.com/rust-lang/rust/issues/109250 It seems no bad happened, r? ``@Nilstrieb``
2023-05-15Always fall back to PartialEq when a constant in a pattern is not ↵Oli Scherer-40/+53
recursively structural-eq
2023-05-10Adjust tests for new drop and forget lintsUrgau-0/+9
2023-05-10refactor(resolve): clean up the early error return caused by non-callbohan-6/+9
2023-05-05tweak spans for `ref mut` suggestionEzra Shaw-2/+2
2023-05-01fix testsyukang-9/+6
2023-05-01Rip it outNilstrieb-15/+13
My type ascription Oh rip it out Ah If you think we live too much then You can sacrifice diagnostics Don't mix your garbage Into my syntax So many weird hacks keep diagnostics alive Yet I don't even step outside So many bad diagnostics keep tyasc alive Yet tyasc doesn't even bother to survive!
2023-04-21Run `check_match` and `check_liveness` when MIR is built instead of having ↵Oli Scherer-207/+207
an explicit phase for them
2023-04-03Reinstate confusion note.Camille GILLOT-0/+4
2023-04-03Perform match checking on THIR.Camille GILLOT-179/+179
2023-04-03Shrink binding span.Camille GILLOT-413/+273
2023-03-27Add notes to non-structural const in pattern error messageJamen Marz-0/+32
2023-03-15error-msg: impl better suggestion for `E0532`Ezra Shaw-0/+136
2023-03-13resolve: Remove `struct_field_names_untracked`Vadim Petrochenkov-2/+2
2023-01-30Modify primary span label for E0308Esteban Küber-12/+12
The previous output was unintuitive to users.
2023-01-26Rollup merge of #106978 - mejrs:mir_build3, r=davidtwcoMatthias Krüger-208/+208
Migrate mir_build's borrow conflicts This also changes the error message slightly, for two reasons: - I'm not a fan of saying "value borrowed, by `x`, here" - it simplifies the error implementation significantly.
2023-01-25Rollup merge of #106897 - estebank:issue-99430, r=davidtwcoMatthias Krüger-0/+2
Tweak E0597 CC #99430
2023-01-20Change `bindings_with_variant_name` to deny-by-default--global-29/+27
2023-01-17Migrate mir_build's borrow conflictsmejrs-208/+208
2023-01-15Tweak E0597Esteban Küber-0/+2
CC #99430
2023-01-14suggest fix for attempted integer identifier in patternsEzra Shaw-0/+42
2023-01-11Translate `Overlap` eagerlymejrs-0/+1
2023-01-11Don't recommend `if let` if `let else` worksmejrs-10/+2
2023-01-11Migrate pattern matchingmejrs-59/+65
2023-01-11Migrate deconstruct_pat.rsmejrs-1/+0
2023-01-11Move /src/test to /testsAlbert Larsan-0/+14295