comp.lang.ada
 help / color / mirror / Atom feed
From: Matt Borchers <mattborchers@gmail.com>
Subject: Re: potential Ada feature - comments?
Date: Tue, 10 Sep 2019 17:35:45 -0700 (PDT)
Date: 2019-09-10T17:35:45-07:00	[thread overview]
Message-ID: <a1312e9e-0724-4e87-98da-a38c54784f03@googlegroups.com> (raw)
In-Reply-To: <ql8sk7$6de$1@gioia.aioe.org>

Yes, I agree that a nested block is an option but it looks crappy and is it okay to complain that everything has to be unnecessarily indented to accommodate this fairly common construct?

Not everything is well designed or uses controlled objects.  In my case, I utilize a lot of legacy Ada 83 code.

procedure SUBPROGRAM is
begin
  begin
    --acquire resources
    ...
  exception
   when X =>
      --something for X
   when Y =>
      --something for Y
   when Z =>
      --something for Z
   when others =>
      --general case
  end;
  --free resources;
end SUBPROGRAM;

  reply	other threads:[~2019-09-11  0:35 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-10 17:52 potential Ada feature - comments? Matt Borchers
2019-09-10 19:13 ` Dmitry A. Kazakov
2019-09-11  0:35   ` Matt Borchers [this message]
2019-09-11  7:54     ` Dmitry A. Kazakov
2019-09-13  1:14       ` Matt Borchers
2019-09-11 16:00     ` G. B.
2019-09-11  9:55 ` fabien.chouteau
replies disabled

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