mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 14:24:45 +00:00
Decision tree compilation of list patterns
This commit is contained in:
parent
da1d937277
commit
ae71c7efe2
7 changed files with 479 additions and 38 deletions
|
@ -93,7 +93,7 @@ impl ListArity {
|
|||
/// The trivially-exhaustive list pattern `[..]`
|
||||
const ANY: ListArity = ListArity::Slice(0, 0);
|
||||
|
||||
fn min_len(&self) -> usize {
|
||||
pub fn min_len(&self) -> usize {
|
||||
match self {
|
||||
ListArity::Exact(n) => *n,
|
||||
ListArity::Slice(l, r) => l + r,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue