If you think of it as “if ˜do what i want’ did not produce an error then do not start over”, it maps easily to a repeat loop with an exit repeat after the do what I want. If do something else is a ˜no-op’, the entire [b]on error[b] section could be omitted, leaving only the surrounding try block.
repeat
try
doWhatIWant()
exit repeat
on error m
doSomethingElse(m)
end try
end repeat
to doWhatIWant()
display dialog "Choose a fate:" buttons {"Success", "Failure"}
if button returned of result is "Failure" then error "Failure!"
"Success"
end doWhatIWant
to doSomethingElse(errMsg)
display dialog "Error: "" & errMsg & """
end doSomethingElse