Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!zaphod.mps.ohio-state.edu!rpi!uupsi!sunic!bmc.uu.se!kuling!mizar.docs.uu.se!daniel From: daniel@mizar.docs.uu.se (Daniel Wengelin) Newsgroups: comp.lang.ada Subject: semantics of exception when exiting a procedure Keywords: exception out-parameter Message-ID: <1616@kuling.UUCP> Date: 15 Aug 90 09:29:50 GMT Sender: news@kuling.UUCP Reply-To: daniel@mizar.docs.uu.se (Daniel Wengelin) Organization: Dept of Computer Systems, Uppsala University, Sweden Lines: 28 Question: What are the semantics when a procedure with out parameters is exited by an exception. Can the out parameters be used, if they have been assigned prior to the exception ? Example> procedure X(P1,P2,P3:out...)is .. P1:=.... if ... raise E1;.... P2:=.... if .... raise E2;.... P3:=... end X; ..... X(P1,P2,P3); Do_Something_With(P1,P2,P3); exception when E1=>Do_Something_With(P1); when E2 => Do_Something_With(P1,P2); .. It would appear that the above code should work, but it does seem a bit risky. I would very much appreciate a LRM ref on this one ! /dw/