patma
patma copied to clipboard
Pattern Matching
This may look as a rehash of #120, but it's not. I don't want to push for a specific solution, but I'd like to turn it into a question/concern to...
Something that is not 100% clear to me is what happens with exceptions raised while matching. The only description I found is [here](https://www.python.org/dev/peps/pep-0622/#guards) «If evaluating a guard raises an exception,...
There were several commenters on today's revealing of the PEP on python-dev who want an `else` clause instead of `case _:` to enter final catch-all block. It's not terrible. If...
People seem uneasy with our use of `_` as a wildcard. Some proposals that have been made: - `*` - `...` - `?` This seems to be an important thing...
A few people on python-dev don't seem to like or understand `case 401|403|404:`. A number of different alternative proposals have been made: - `case 401 or 403 or 404:` -...
This discussion was started in #8, but now that issue is mostly about `__match__()` API. So I would like to open a separate issue about providing some utilities/helpers for pattern...
I find the term "reference patterns" confusing (somehow I thought that was a fancy name for "name patterns" :-). Can we rename these to "constant patterns"? While they can technically...
Taine brought this up in private email: > Beside of renaming “name patterns” to “capturing patterns”, could we rename "named sub-patterns" to AS patterns? AS pattern is also a traditional...
I was about to describe some weird cases and limitations and issues I think the `__match__()` protocol has, but instead of that I think something simpler can be done: getting...