3 ms·
In many languages match is an expression, so you can do things like `x = match y { ... }`, which is a very common use case. I don't write much Python these day
by the_duke 6y ago
In many languages match is an expression, so you can do things like `x = match y { ... }`, which is a very common use case.
I don't write much Python these days, but it being a statement rather than an expression is disappointing
It forces you to use a separate "output" variable or `return`.