|
|
|
|
|
by CDSlice
2192 days ago
|
|
Although it won't be as concise, you can use guards to emulate this feature with match data:
case [x1, x2] if x1 == x2:
...
I agree on this being a fantastic addition to the language. I've sorely missed not having pattern matching in Python after using Rust. |
|