Piers Cawley wrote:
> 
> The (continue|always|finally|whatever) clause will *always* be
> executed, even if one of the catch clauses does a die, so you can use
> this to roll back the database transaction or whatever else was going
> on and restore any invariants.

Which makes me think that it would be nice if the continue block could
come before the catch block(s):

        establish_invariants();
        try {
                something_risky();
        }
        continue {
                restore_invariants();
        }
        catch {
                handle_error_assuming_invariants_restored();
        }

-- 
John Porter

Reply via email to