Path: utzoo!mnetor!uunet!husc6!necntc!necis!mrst!sdti!mjy From: mjy@sdti.UUCP (Michael J. Young) Newsgroups: comp.lang.c++ Subject: Re: Try/Recover in C++ ??? Message-ID: <204@sdti.UUCP> Date: 27 Jan 88 17:04:14 GMT References: <6590011@hplsla.HP.COM> Reply-To: mjy@sdti.UUCP (0000-Michael J. Young) Organization: Software Development Technologies, Sudbury MA Lines: 25 In article <6590011@hplsla.HP.COM> jima@hplsla.HP.COM ( Jim Adcock) writes: >Has anyone figured out a good way to do "try/recover-type" schemes in C++ >without hacking up the language? >... >Any other bright ideas on how to recover from errors within a body of >software [that may include c++ functions]? We've been dealing with this very problem on our project, and have come up with what I think is a fairly elegant and generic error handling package which requires no changes to the language itself. William Miller, who designed and implemented the package, has submitted an article to Computer Language on the subject. It is currently being reviewed for possible publication in the May issue. The design not only ensures that destructors will be called when stack frames are discarded, but also implements the best features of Ada exception handlers and PL/I on-units while avoiding some of the disadvantages of each. I won't attempt to go into a lengthy description of the design, since I couldn't do it justice. The article (I've read a draft) provides plenty of detail. -- Mike Young - Software Development Technologies, Inc., Sudbury MA 01776 UUCP : {decvax,harvard,linus,mit-eddie}!necntc!necis!mrst!sdti!mjy Internet : mjy%sdti.uucp@harvard.harvard.edu Tel: +1 617 443 5779