[Python-ideas] with-statement syntactic quirk
Joachim König
him at online.de
Wed Oct 31 17:37:58 CET 2012
On 31/10/2012 16:42, Guido van Rossum wrote:
> Yeah, the problem is that when you see a '(' immediately after 'with',
> you don't know whether that's just the start of a parenthesized
> expression or the start of a (foo as bar, blah as blabla) syntactic
> construct.
but couldn't "with" be interpreted as an additional kind of opening
parantheses (and "if", "for", "while",
"elif", "else" too) and the ":" as the closing one?
I'm sure this has been asked a number of times but I couldn't find an
answer.
Joachim
More information about the Python-ideas
mailing list