except clause syntax question
Charles Yeomans
charles at declareSub.com
Mon Jan 30 12:41:00 EST 2012
More information about the Python-list mailing list
Mon Jan 30 12:41:00 EST 2012
- Previous message (by thread): PMW+BLT on windows, any chance?
- Next message (by thread): except clause syntax question
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To catch more than one exception type in an except block, one writes except (A, B, C) as e: I'm wondering why it was decided to match tuples, but not lists: except [A, B, C] as e: The latter makes more sense semantically to me -- "catch all exception types in a list" as opposed to "catch this single thing composed of three exception types". Charles Yeomans
- Previous message (by thread): PMW+BLT on windows, any chance?
- Next message (by thread): except clause syntax question
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list