[Python-bugs-list] [ python-Bugs-701135 ] except: grammar is incorrect

SourceForge.net noreply@sourceforge.net
Mon, 10 Mar 2003 13:15:42 -0800


Bugs item #701135, was opened at 2003-03-10 15:15
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=701135&group_id=5470

Category: Documentation
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Mark Ferris (mferris1)
Assigned to: Nobody/Anonymous (nobody)
Summary: except: grammar is incorrect

Initial Comment:
In the Python Language Reference manual, it shows the try-
except grammar as:
try_exc_stmt::= "try" ":" 
suite
("except" [expression ["," target]] ":" 
suite)+

This implies that this is a valid except 
stanza:
except TypeError or VaueError or 
KeyError:

This syntax does not produce any errors, but it 
doesn't work as one would expect either.  It only "excepts" the first 
exception in the expression; i.e. TypeError in this 
example.

I am assuming the grammar doc just needs to be 
updated and this is not the intented syntax for except.


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=701135&group_id=5470