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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,fee8802cc3d8334d X-Google-Attributes: gid103376,public From: Samuel Mize Subject: Re: Ada and Java. different behaviour. casting long to int problem. Date: 1999/06/19 Message-ID: <7kgqqd$1dai@news2.newsguy.com>#1/1 X-Deja-AN: 491521021 References: <7jt2c0$vrb@drn.newsguy.com> <7k64t7$igo$1@its.hooked.net> <7k689a$ci2@drn.newsguy.com> <3766C842.E1EAB60A@pwfl.com> <3766D1CC.D712895E@itools.symantec.com> <7k8nn5$qcb$1@its.hooked.net> <3767E8A2.EF1A0570@itools.symantec.com> <7k8tv3$3gm@drn.newsguy.com> <3769506F.157411C0@mitre.org> <7kbujm$1kb@drn.newsguy.com> <7ke2dg$2a7a@drn.newsguy.com> Organization: ImagiNet Communications, Ltd. User-Agent: tin/pre-1.4-981002 ("Phobia") (UNIX) (AIX/3-2) Newsgroups: comp.lang.ada Date: 1999-06-19T00:00:00+00:00 List-Id: Hyman Rosen wrote: > But when the code must do its > job correctly, always, even the first time, then overflow and bounds checking > should be turned off in the field, because that way, it's more likely that > the program will be able to complete its job. I can't agree. This kind of code should have exception "firewalls" built into it, so that the overflow and bounds checking help you isolate and handle problems like corrupted data and bad memory elements. For some systems, wraparound or saturating semantics may provide a safe failure mode. For others it wouldn't wouldn't. However, I do agree with you on this: the fact that the language will raise an exception does NOT inherently make software more reliable. The software must be written to take advantage of the exceptions. Otherwise, it's a toss-up whether catastrophe is more likely from saturation, wrap-around or exceptions -- it's application-dependent. I think Ariane demonstrates this very well. Best, Sam Mize -- Samuel Mize -- smize@imagin.net (home email) -- Team Ada Fight Spam: see http://www.cauce.org/ \\\ Smert Spamonam