Terry Reedy tjre...@udel.edu writes:
I do not have any information on the topic, but I *imagine* that the
when RETURN_VALUE opcode is evaluated within the context of an except
block, it triggers a check for whether a corresponding finally block
exists and should it exist, it is triggered, much
On Thu, Jan 30, 2014 at 11:05 PM, Dave Angel da...@davea.name wrote:
The finally has to happen before any return inside the try or the
except. And once you're in the finally clause you'll finish it
before resuming the except clause. Since it has a return, that
will happen before the
On 2014-01-30 13:02, Chris Angelico wrote:
On Thu, Jan 30, 2014 at 11:05 PM, Dave Angel da...@davea.name wrote:
The finally has to happen before any return inside the try or the
except. And once you're in the finally clause you'll finish it
before resuming the except clause. Since it has a
On Fri, Jan 31, 2014 at 12:11 AM, MRAB pyt...@mrabarnett.plus.com wrote:
One of the reasons that the 'with' statement was added was to prevent
the mistake that you've just done. ;-)
What if the file can't be opened?
Yeah, whoops. The open shouldn't be inside try/finally.
def func():
On 30/01/2014 06:33, Andrew Berg wrote:
On 2014.01.29 23:56, Jessica Ross wrote:
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after try
...
On 01/30/2014 10:12 AM, Rotwang wrote:
On 30/01/2014 06:33, Andrew Berg wrote:
On 2014.01.29 23:56, Jessica Ross wrote:
I found something like this in a StackOverflow discussion.
-- def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
...
On 1/30/2014 7:05 AM, Dave Angel wrote:
Jessica Ross deathwea...@gmail.com Wrote in message:
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after try
... return True
... finally:
... print Finally
...
On Jan 29, 2014 11:01 PM, Jessica Ross deathwea...@gmail.com wrote:
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after try
...
On 2014.01.29 23:56, Jessica Ross wrote:
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after try
... return True
... finally:
Le jeudi 30 janvier 2014 06:56:16 UTC+1, Jessica Ross a écrit :
I found something like this in a StackOverflow discussion.
def paradox():
... try:
... raise Exception(Exception raised during try)
... except:
... print Except after try
...
11 matches
Mail list logo