comp.lang.ada
 help / color / mirror / Atom feed
From: blaak@mda.ca (Ray Blaak)
Subject: Re: Help with Exceptions! (fwd)
Date: 1996/05/08
Date: 1996-05-08T00:00:00+00:00	[thread overview]
Message-ID: <4mqhj3$sp7@map.mda.ca> (raw)
In-Reply-To: Pine.BSI.3.91.960508012641.2120A-100000@pentagon.io.com


Actually, the gotos and extra returns are unnecessary, for the natural control
flow will accomplish the same thing:

procedure test is
  x:integer;
begin
  begin
    x := 10000000;
  exception
    when Constraint_Error => null;
  end;
  begin
    x := 3;
  exception
    when Constraint_Error => null;
  end;
end test;

Dave <davedave@io.com> writes:
>procedure test is
>        x:integer ;
>begin
>	begin
>	        x := 10000000 ;
>        exception
>		when CONSTRAINT_ERROR =>
>			goto Next_Block ;
>	end ;
><<Next_Block>>
>	begin
>		x := 3 ;
>        exception
>		when CONSTRAINT_ERROR =>
>			RETURN ;
>	end ;
>	RETURN ;
>end test;


Cheers,
Ray Blaak
blaak@mda.ca




      reply	other threads:[~1996-05-08  0:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-05-08  0:00 Help with Exceptions! (fwd) Dave
1996-05-08  0:00 ` Ray Blaak [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox