[Python-Dev] Py3k: Except clause syntax (original) (raw)
Michael Urman murman at gmail.com
Thu Mar 16 15:57:37 CET 2006
- Previous message: [Python-Dev] Py3k: Except clause syntax
- Next message: [Python-Dev] Py3k: Except clause syntax
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 3/16/06, Georg Brandl <g.brandl at gmx.net> wrote:
+1. Fits well with the current use of "as".
I like it, but wonder about the false parallels below. My initial reaction is it's not worth worrying about as it's easy to learn as part of the import or except statements, and should do the right thing. Nobody would expect the second import to rename both items to q, and the first except clause would be a SyntaxError.
from foo import bar as b, quux as q
except TypeError as te, IndexError as ie
from foo import bar, quux as q
except TypeError, IndexError as e
Michael
Michael Urman http://www.tortall.net/mu/blog
- Previous message: [Python-Dev] Py3k: Except clause syntax
- Next message: [Python-Dev] Py3k: Except clause syntax
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]