On 3 February 2012 15:02, Nick Coghlan <ncoghlan at gmail.com> wrote: > Both will be allowed - in 3.x, '...' is just an ordinary expression > that means exactly the same thing as the builtin Ellipsis: > > >>> Ellipsis > Ellipsis > >>> ... > Ellipsis > I'd totally forgotten that was the case in 3.x ... it's still not exactly common to use Ellipsis/... directly except in extended slicing. > Sane code almost certainly won't include *either* form, though. If > you're reraising an exception, you should generally be leaving > __cause__ and __context__ alone, and if you're raising a *new* > exception, then __cause__ will already be Ellipsis by default - you > only need to use "raise X from Y" to set it to something *else*. > Absolutely - I can't think of a reason to want to reraise an existing exception while supressing any existing __cause__ in favour of __context__. But I'm sure someone can. Tim Delaney -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/python-dev/attachments/20120203/b710299d/attachment.html>
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4