From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: * X-Spam-Status: No, score=1.6 required=5.0 tests=BAYES_05,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,743cbb1eadac54f3,start X-Google-Attributes: gid103376,public From: michiel.perdeck@tip.nl (Michiel Perdeck) Subject: question on exceptions Date: 1996/11/02 Message-ID: #1/1 X-Deja-AN: 194090029 sender: news@tip.nl (The News User) x-nntp-posting-host: utrecht42.pop.tip.nl organization: CMG reply-to: michiel.perdeck@cmg.nl newsgroups: comp.lang.ada Date: 1996-11-02T00:00:00+00:00 List-Id: Intro: This is one of several questions on Ada95 after reading the "Ada guide for C/C++ programmers" from Simon Johnston. I am a fan of Ada and I think that much (if not most) C/C++ programs should have been written in Ada. I have, however, not been able to use Ada as much as I would have liked. I have split my questions over a few messages so that reactions may be given to individual questions. Questions: Unlike an exception in C++, an Ada exception cannot carry any extra information besides it's own name. In C++ you can have an exception of a certain class e.g. SQL_Exception, and then put a message in an exception when it occurs. The exception handler can then use that information to write on a log-file or the like. It seems to me that this is a more flexible concept (exceptions as objects) than that of Ada (exceptions as scalar types). I hope you can convince me that I'm wrong! What do you think? Regards, Michiel Perdeck Michiel Perdeck CMG AT Finance, Amstelveen, Netherlands michiel.perdeck@cmg.nl michiel.perdeck@tip.nl