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=0.2 required=5.0 tests=BAYES_00,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,28396555259c7864 X-Google-Attributes: gid103376,public From: JP Thornley Subject: Re: AQS95 floatin point relational tests Date: 1997/03/12 Message-ID: <552293175wnr@diphi.demon.co.uk>#1/1 X-Deja-AN: 225026916 References: <33241A3A.191B@lmco.com> X-Mail2News-User: jpt@diphi.demon.co.uk X-Mail2News-Path: relay-11.mail.demon.net!relay-10.mail.demon.net!diphi.demon.co.uk Organization: None Reply-To: jpt@diphi.demon.co.uk Newsgroups: comp.lang.ada Date: 1997-03-12T00:00:00+00:00 List-Id: In article: dewar@merv.cs.nyu.edu (Robert Dewar) writes: > No, there is no FAQ on this issue, it is not an FAQ (it has come up > twice in the history of CLA). If you have an old archive of CLA, you > may be able to find the old thread. > The results of delving into my own archive is given below. Clearly, anyone using the AQS should look carefully at 5.5.6 and 7.2.7, as well as 7.2.2 to 7.2.4, and make the most sensible interpretation they can of the relevant issues (bearing in mind that many people don't understand the extent to which they don't understand the issues, and that definitely includes me). My original question (extract):- I'm having difficulty understanding the statements in the Ada Quality and Style Guide on the portability of relational expressions with real operands:- Section 5.5.6 - "... the use of <= is more portable than either < or =" Section 7.2.7 (in the Chapter on Portability) - "Strict relational comparisons (<, >, =, /=) are a general problem with computations involving real numbers" Robert Dewar's response (extract):- Anmd wonders about the above quotes from AQ&S. To me they are plain incorrect ... The idea that equality testing on fpt numbers is always wrong is a myth borne of unfamiliarity with floating-point semantics that refuses to die! The idea that the use of <= is more portable than either < or = is particular rubbish, I see no possible justification for such a statement, and, unlike the old rule about avoiding equality, I cannot even guess the thought behind this misunderstanding. Tucker Taft's response:- This is a bug in AQ&S. Several of the reviewers of AQ&S pointed out this mistake, but alas, it somehow managed to slip through. One claim was that this statement was due to Norman Cohen, and hence indisputable. However, Norm (or at least NC1, as we used to call his non-alter-ego ;-) has since disavowed all connection with this statement. and finally Norman Cohen's response:- Tucker Taft wrote: > This is a bug in AQ&S. Several of the reviewers of AQ&S pointed out > this mistake, but alas, it somehow managed to slip through. One claim > was that this statement was due to Norman Cohen, and hence indisputable. Interesting argument, but I've rarely been able to use it successfully. ;-) > However, Norm (or at least NC1, as we used to call his non-alter-ego ;-) > has since disavowed all connection with this statement. We *ALL* disavow any connection with this statement. Hope this all helps. Phil Thornley -- ------------------------------------------------------------------------ | JP Thornley EMail jpt@diphi.demon.co.uk | ------------------------------------------------------------------------