Esteban Küber
5c3e01a340
On resolve error of [rest..], suggest [rest @ ..]
...
When writing a pattern to collect multiple entries of a slice in a
single binding, it is easy to misremember or typo the appropriate syntax
to do so, instead writing the experimental `X..` pattern syntax. When we
encounter a resolve error because `X` isn't available, we suggest
`X @ ..` as an alternative.
```
error[E0425]: cannot find value `rest` in this scope
--> $DIR/range-pattern-meant-to-be-slice-rest-pattern.rs:3:13
|
LL | [1, rest..] => println!("{rest:?}"),
| ^^^^ not found in this scope
|
help: if you meant to collect the rest of the slice in `rest`, use the at operator
|
LL | [1, rest @ ..] => println!("{rest:?}"),
| +
```
Fix #88404 .
2023-11-17 00:55:55 +00:00
..
2023-01-11 09:32:08 +00:00
2023-10-05 01:04:41 +00:00
2023-05-21 14:16:41 +02:00
2023-11-08 20:42:32 +00:00
2023-06-24 18:41:27 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-11 09:32:08 +00:00
2023-10-30 00:15:49 +00:00
2023-10-30 00:15:49 +00:00
2023-10-30 00:15:49 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-20 02:26:12 -05:00
2023-01-20 02:26:12 -05:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-20 02:26:12 -05:00
2023-01-20 02:26:12 -05:00
2023-01-11 09:32:08 +00:00
2023-04-03 15:59:21 +00:00
2023-10-11 12:49:57 +00:00
2023-10-11 12:49:57 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-05-24 19:35:59 -03:00
2023-11-03 18:26:16 +01:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-14 12:51:20 +13:00
2023-04-03 15:59:21 +00:00
2023-03-15 22:19:54 +13:00
2023-03-15 22:19:54 +13:00
2023-03-15 22:19:54 +13:00
2023-07-01 02:28:15 -04:00
2023-09-07 11:07:33 +08:00
2023-09-07 11:07:33 +08:00
2023-10-15 19:20:06 +08:00
2023-10-15 19:20:06 +08:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-10-16 15:57:59 +00:00
2023-10-16 15:57:59 +00:00
2023-10-16 15:57:59 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-03-13 17:31:55 +04:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-11 09:32:08 +00:00
2023-10-05 01:04:41 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-05-10 22:35:01 +08:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-30 20:12:19 +00:00
2023-11-17 00:55:55 +00:00
2023-11-17 00:55:55 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2023-07-17 22:06:32 +00:00
2023-07-17 22:06:32 +00:00
2023-07-17 22:06:32 +00:00
2023-07-17 22:02:09 +00:00
2023-07-17 22:02:09 +00:00
2023-07-28 11:20:11 +00:00
2023-10-04 02:04:14 +00:00
2023-07-17 22:06:32 +00:00
2023-04-03 15:59:21 +00:00
2023-01-11 09:32:08 +00:00
2023-04-03 15:59:21 +00:00