Let take this program as example:
Program J {
throw:=null
exit_stmt_reached := false
call P[throw]
if !exit_stmt_reached then {
call Q[throw]
}
}
The program 'P' throws an exception. But, if that happend at the end of execution of P, the variable exit_stmt_reached is still in true. So when the invocation to program 'Q' occurs, we lost the exception value.
Fix: Every statement should be surrounded by the condition (!exit_stmt_reached && throw != null).
This bug was fixed by adding the condition mentioned. Please, test it an close it.