Consider the following Ada code fragment:
Error_1, Error_2 : exception;
task Watch;
task Signaller;
protected Atc is
entry Go;
procedure Signal;
private
Flag : Boolean := False;
end Atc;
protected body Atc is
entry Go when Flag is
begin
raise Error_1;
end Go;
procedure Signal is
begin
Flag : = True;
end Signal;
end Atc;
task body watch is
begin
...
select
Atc. Go;
then abort
-- code taking 100 millisecond
raise Error 2;
end select;
...
exception
when Error_1 $\Rightarrow$
Put_Line("Error_1 Caught");
when Error_2 =>
Put_Line("Error_2 Caught");
when others $\Rightarrow$
Put_Line("Other Errors Caught");
end watch;
task body Signaller is
begin
$+\cdots$
Atc. Signal;
...
end Signaller;
Describe carefully the possible executions of this program fragment assuming that context switches between tasks can happen at any time.