On Fri., 3 Jul. 2020, 2:27 am MRAB, <pyt...@mrabarnett.plus.com> wrote:
> > IMHO, the assignment statement should remain as it is, not sometimes > assign and sometimes not. > > There could be another form that does matching: > > try ?x, 0 = (4,5) > Huh, this made me wonder if "match/try" may fit people's brains better than "match/case". I know for me that I want to read case clauses the same way I would read them in C, which is thoroughly unhelpful. The following looks weird though, so I don't think I actually like it in practice: === match shape: try Point(x, y): ... try Rectangle(x0, y0, x1, y1, painted=True): ... === Cheers, Nick. >
_______________________________________________ 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/H6ZNPMH5T5PY265DGSL7OMSZZH4UDJSJ/ Code of Conduct: http://python.org/psf/codeofconduct/