Jonathan Brouwer
b17df9b99a
Rollup merge of #149952 - Delta17920:fix/149777-range-destructuring, r=fmease
...
Suggest struct pattern when destructuring Range with .. syntax
implemented a new diagnostic in rustc_resolve to detect invalid range destructuring attempts (e.g., let start..end = range). The fix identifies when resolution fails for identifiers acting as range bounds specifically handling cases where bounds are parsed as expressions and suggests the correct struct pattern syntax (std::ops::Range { start, end }). This replaces confusing "cannot find value" errors with actionable help, verified by a new UI test covering various identifier names.
Fixes rust-lang/rust#149777
2025-12-18 18:37:16 +01:00
..
2025-04-08 23:06:31 +03:00
2024-02-16 20:02:50 +00:00
2024-02-15 17:20:44 +00:00
2024-02-15 17:20:44 +00:00
2025-02-04 21:42:43 +05:30
2024-04-29 14:53:38 +02:00
2025-01-23 20:51:29 +08:00
2025-01-23 20:51:29 +08:00
2025-08-05 19:34:46 +05:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2025-07-24 17:01:44 -04:00
2025-04-08 23:06:31 +03:00
2024-11-17 23:40:00 +00:00
2024-02-16 20:02:50 +00:00
2023-11-24 19:15:52 +01:00
2024-02-16 20:02:50 +00:00
2024-03-09 01:13:42 +01:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2024-03-03 16:30:48 -03:00
2024-03-03 16:30:48 -03:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2025-02-14 00:44:10 -08:00
2024-12-04 20:29:36 +00:00
2024-02-16 20:02:50 +00:00
2024-12-04 20:29:36 +00:00
2024-12-04 20:29:36 +00:00
2023-11-24 19:15:52 +01:00
2025-04-16 11:10:10 +02:00
2025-07-28 17:35:09 +03:00
2025-12-02 18:25:13 +00:00
2024-02-16 20:02:50 +00:00
2023-11-24 19:15:52 +01:00
2025-12-17 14:53:14 +00:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2024-02-16 20:02:50 +00:00
2023-11-03 18:26:16 +01:00
2024-02-15 15:44:46 +00:00
2025-01-23 20:51:29 +08:00
2025-12-16 02:10:08 +09:00
2025-12-16 02:10:08 +09:00
2025-01-23 20:51:29 +08:00
2024-06-23 04:28:42 -05:00
2024-11-23 08:57:25 -07:00
2023-11-24 19:15:52 +01:00
2024-12-12 23:36:27 +00:00
2023-11-24 19:15:52 +01:00
2023-11-24 19:15:52 +01:00
2024-02-16 20:02:50 +00:00
2025-12-07 10:37:45 +09:00
2025-12-07 10:37:45 +09:00
2023-11-24 19:15:52 +01:00
2025-02-10 20:21:39 +00:00
2025-12-16 02:10:08 +09:00
2025-12-02 18:28:05 +00:00
2025-12-02 18:28:05 +00:00
2023-11-24 19:15:52 +01:00
2023-11-24 19:15:52 +01:00
2024-02-16 20:02:50 +00:00
2025-12-08 07:06:13 +09:00
2025-12-08 07:06:13 +09:00
2025-12-16 02:10:08 +09:00
2025-12-16 02:10:08 +09:00
2025-04-30 10:44:24 +03:00
2023-11-24 19:15:52 +01:00
2023-11-24 19:15:52 +01:00
2023-11-24 19:15:52 +01:00
2023-11-27 16:19:02 +00:00
2023-11-27 16:19:02 +00:00
2024-12-12 23:36:27 +00:00
2023-11-24 19:15:52 +01:00
2025-12-13 00:54:20 +09:00
2023-11-24 19:15:52 +01:00
2025-01-23 20:51:29 +08:00
2025-08-27 00:23:26 -04:00
2025-08-27 00:23:26 -04:00
2025-08-27 15:06:05 -04:00
2025-08-27 15:06:05 -04:00
2025-08-05 19:34:46 +05:00
2023-08-14 21:43:56 +00:00
2023-11-24 19:15:52 +01:00
2025-07-31 21:25:49 +05:00
2025-07-31 21:25:49 +05:00
2025-11-27 14:13:58 -05:00
2025-11-27 14:13:58 -05:00
2025-07-31 21:25:49 +05:00
2024-02-16 20:02:50 +00:00
2025-03-07 16:16:41 +01:00
2025-03-07 16:16:41 +01:00
2023-11-24 19:15:52 +01:00
2025-07-31 21:25:49 +05:00
2025-07-31 21:25:49 +05:00
2025-07-31 21:25:49 +05:00
2025-08-05 19:34:46 +05:00
2025-10-11 21:59:51 -04:00
2025-10-11 21:59:51 -04:00
2025-08-04 16:43:53 -04:00
2025-08-04 16:43:53 -04:00
2025-08-04 16:43:53 -04:00
2025-12-02 18:28:05 +00:00
2025-12-02 18:28:05 +00:00