bors 2ca8d358e5 Auto merge of #112549 - jieyouxu:fix-tests-for-unit-bindings, r=Nilstrieb
Adjust UI tests for `unit_bindings` lint

- Explicitly annotate `let x: () = expr;` where `x` has unit type, or remove the unit binding to leave only `expr;` instead.
- Use `let () = init;` or `let pat = ();` where appropriate.
- Fix disjoint-capture-in-same-closure test which wasn't actually testing a closure: `tests/ui/closures/2229_closure_analysis/run_pass/disjoint-capture-in-same-closure.rs`.

Note that unfortunately there's *a lot* of UI tests, there are a couple of places where I may have left something like `let (): ()` (this is not needed but is left over from an ealier version of the lint) which is bad style.

This PR is to help with the `unit_bindings` lint at #112380.
2023-06-13 13:07:43 +00:00
..
2023-04-03 09:24:11 +02:00
2023-02-09 10:26:49 +00:00
2023-05-08 03:36:30 +00:00
2023-05-12 00:10:52 +00:00
2023-01-11 14:40:02 -08:00
2023-01-11 14:40:02 -08:00
2023-05-08 03:36:30 +00:00
2023-05-08 03:36:30 +00:00
2023-01-30 20:12:21 +00:00
2023-05-12 00:10:52 +00:00
2023-05-01 16:15:13 +08:00
2023-05-01 16:15:13 +08:00
2023-05-12 00:10:52 +00:00
2023-04-16 11:38:52 +00:00
2023-03-08 00:00:18 +00:00
2023-03-08 00:00:18 +00:00
2023-04-08 21:32:55 +00:00
2023-04-03 09:24:11 +02:00
2023-01-30 20:12:21 +00:00
2023-05-02 14:48:39 +00:00
2023-04-03 09:24:11 +02:00
2023-01-15 19:46:20 +00:00
2023-01-15 19:46:20 +00:00
2023-01-15 19:46:20 +00:00
2023-05-08 03:36:30 +00:00
2023-01-15 19:46:20 +00:00
2023-02-22 21:52:26 +00:00
2023-05-02 22:36:24 +00:00
2023-05-08 03:36:30 +00:00
2023-04-07 18:07:11 +10:00
2023-03-06 21:05:35 +08:00