Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
pejoculant
· 14y ago · 0 comments
Compound with statements are nice, put this is not a 3.1 feature. This was added in 2.7:
http://docs.python.org/reference/compound_stmts.html#the-wit...
Comments
[–]
archangel_one
14y ago
Despite the numbering, 2.7 was released a year after 3.1. It added a bunch of features that helped compatibility with 3.x.
[–]
throwaway54-762
14y ago
Thanks, I forgot about that.
[–]
briancurtin
14y ago
It was a feature to both. Check the same document for the 3.1 release (and the What's New).
[–]
koenigdavidmj
14y ago
And you could hack this with contextlib.nested before.