This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author twouters
Recipients twouters
Date 2014-02-22.23:56:53
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Here is a preliminary implementation of PEP 463, minus mandatory parentheses and with the most straightforward precedence rule: equal to if-expr -- which means this:

A if C else B except E: D

is parsed as

A if C else (B except E: D)

(because of associativity, not precedence) and not as

(A if C else B) except E: D

as suggested by the PEP with the hand-wavy words 'between lambda and if/else in precedence'. The latter is possible but means a little more hoop-jumping in the grammar.

The tests included are rudimentary (at the end of and could probably do with some fleshing out, partially as tests and partially to try out how the precedence rules work out in practice.
Date User Action Args
2014-02-22 23:56:57twouterssetrecipients: + twouters
2014-02-22 23:56:57twouterssetmessageid: <>
2014-02-22 23:56:57twouterslinkissue20739 messages
2014-02-22 23:56:56twouterscreate