It would be fantastic if these were expressions rather than statements. Imagine being able to write things like:
```python @memoized def fibonacci(n): match n: case 0: (return/yield?) 0 case 1: 1 case _: fibonacci(n - 2) + fibonacci(n - 1) ``` Obviously this could be written easily with an if statement, and might not be the best example. But I’ve often encountered situations where I wish I had semantics like this. Jens ------------------------------------------------------------------- The information contained in this message may be CONFIDENTIAL and is intended for the addressee only. Any unauthorized use, dissemination of the information or copying of this message is prohibited. If you are not the addressee, please notify the sender immediately by return e-mail and delete this message. Thank you _______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/PLPOHR623XNAT4ZEQGSRFDKUBTK3PWVK/ Code of Conduct: http://python.org/psf/codeofconduct/