Skip to content

Commit

Permalink
wildcard pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
tomara-x committed Sep 25, 2024
1 parent 153ea7c commit d6af44c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/eval/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ pub fn pat_ident(pat: &Pat) -> Option<String> {
match pat {
Pat::Ident(expr) => Some(expr.ident.to_string()),
Pat::Type(expr) => pat_ident(&expr.pat),
Pat::Wild(_) => Some(String::from("_")),
_ => None,
}
}
Expand Down

0 comments on commit d6af44c

Please sign in to comment.