(no title)
gergo_barany | 1 year ago
> The one-sided pattern matching seems to be a peculiarity of Elixir.
And Erlang. And Haskell. And OCaml. And F#. And...
All of these "languages mentioned above" have one-sided pattern matching. This was the claim. Not more, not less. Are you disagreeing with this claim? Are you trying to say something about "one-sided pattern matching"? Or are you trying to say something about something other than "one-sided pattern matching"? You are not being clear.
weatherlight|1 year ago
Elixir's pattern matching is more like unification. For example:
This kind of pattern matching, where a variable can appear multiple times on the left-hand side and must match the corresponding parts of the list, can't be done easily in Haskell or OCaml. In those languages, each variable can only appear once on the left side of a pattern match.the OP is saying that this style of one sided pattern matching is indeed a peculiarity of Elixir (and Erlang)
gergo_barany|1 year ago