Newsgroups: comp.object,comp.lang.eiffel,comp.lang.c++,comp.lang.beta,comp.lang.java,comp.lang.sather Path: news.daimi.aau.dk!news.uni-c.dk!newsfeed.sunet.se!news01.sunet.se!sunic!news99.sunet.se!erinews.ericsson.se!cnn.exu.ericsson.se!newshost.convex.com!news.duke.edu!news.mathworks.com!newsfeed.internetmci.com!howland.reston.ans.net!math.ohio-state.edu!newsfeed.acns.nwu.edu!ftpbox!mothost!schbbs!news From: shang@corp.mot.com (David L. Shang) Subject: Re: What Should An Exception Handling Do? -- Clarification of rules Reply-To: shang@corp.mot.com Organization: MOTOROLA Date: Mon, 1 Apr 1996 14:56:58 GMT Message-ID: <1996Apr1.145658.10876@schbbs.mot.com> References: <4jh84e$1b5@ratatosk.uio.no> Sender: news@schbbs.mot.com (SCHBBS News Account) Nntp-Posting-Host: 129.188.128.126 Lines: 22 Xref: news.daimi.aau.dk comp.object:53607 comp.lang.eiffel:22631 comp.lang.c++:176265 comp.lang.beta:10700 comp.lang.java:30725 comp.lang.sather:12387 In article <4jh84e$1b5@ratatosk.uio.no> Jarle Stabell writes: > shang@corp.mot.com (David L. Shang) wrote: > > > result = try do_something() > > { > > when condition1: some_extraordinary_work1; retry; > > when condition2: some_extraordinary_work2; retry; > > when condition3: some_extraordinary_work3; retry; > > when condition4: return null; > > } > > > > I think there's a problem with this "strategy", a user should be able to > cancel this kind of operation, here some_extraordinary_work1..3 don't > seem to give the user a chance to cancel the operation. A return statement within some_extraordinary_work1..3 will cancel the operation, or a throw statement will kick the ball to a catcher outside. David Shang