[LLVMdev] RFC: Exception Handling Proposal Revised

Bill Wendling wendling at apple.com
Wed Dec 1 11:54:32 PST 2010


On Dec 1, 2010, at 11:42 AM, Duncan Sands wrote:

> I got myself confused.  Indeed it seems that C++ behaves the way you describe.
> However in Ada it is the other way round: cleanups are run after handlers.  For
> example in Ada it would be possible to use the variable "a" inside one of the
> handlers, so it had better not be destructed before the handler runs.  Thus it
> is important not to bake "cleanups run before handlers" into your proposal,
> since it is C++ specific.  That said, as far as I can tell you didn't bake it
> in.
> 
Ah! That explains it. :)

Yes, they aren't baked in. You may run the cleanups whenever you wish. Or indeed not at all if you desire. :)

-bw

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20101201/0146ef68/attachment.html>


More information about the llvm-dev mailing list