Sometimes it would be useful to be able to write: def foo(): try: return thing() except ValueError; try: return otherthing() except ValueError; try: return yetotherthing() except ValueError; if shouldraise(): raise
But currently this needs to be written like so: def foo(): try: return thing() except ValueError: try: return otherthing() except ValueError: try: return yetotherthing() except ValueError: if shouldraise(): raise Look at all that unnecessary indentation! Would be nice to get rid of it. _______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/U4YH5O255RBMNXOM3VEUBCDDCHQDFES5/ Code of Conduct: http://python.org/psf/codeofconduct/
