Open
Description
The List Patterns section does not include any example of a patterns that destructures the tail of the list into a variable like [head, ..tail]
. This kind of pattern is then shown in the List Recursion section but in my opinion it should also be included in the patterns page for clarity.
I was looking for this kind of pattern while working on a little project and I assumed that this kind of destructuring wasn't possible because it wasn't mentioned. Including it earlier would help avoid confusion for users exploring list pattern matching.
Metadata
Metadata
Assignees
Labels
No labels