Yuescript
Yuescript copied to clipboard
Pattern matching
One very fundamental tool for functional programming I am missing.
Pattern matching is a technique that is very well known from the Erlang, OCaml, Haskell, etc communities and I love to see it in Yuescript.
Fennel has some, but I dont like to use a lisp. 🤭
There are some implementations in native Lua, but I would like to use them in Yuescript natively.
Tried partially implemented table matching to provide some of the pattern matching functions. You may take a look and give me some ideas about what are still missing. https://yuescript.org/doc/#table-matching