home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!usc!sdd.hp.com!mips!darwin.sura.net!uvaarpa!cv3.cv.nrao.edu!laphroaig!cflatter
- From: cflatter@nrao.edu (Chris Flatters)
- Subject: Re: Power Operator vs NANs
- Message-ID: <1992Jul22.151649.27527@nrao.edu>
- Sender: news@nrao.edu
- Reply-To: cflatter@nrao.edu
- Organization: NRAO
- References: <849@nazgul.UUCP>
- Date: Wed, 22 Jul 1992 15:16:49 GMT
- Lines: 33
-
- In article 849@nazgul.UUCP, bright@nazgul.UUCP (Walter Bright) writes:
- >I don't have the specs in electronic form. But they have been included in
- >the latest ANSI C++ mailing.
- >
- >The additional operators are:
- > < less
- > > greater
- > <= less or equal
- > >= greater or equal
- > == equal
- > != unordered, less or greater
- > !<>= unordered
- > <> less or greater
- > <>= less, equal or greater
- > !<= unordered or greater
- > !< unordered, greater or equal
- > !>= unordered or less
- > !> unordered, less or equal
- > !<> unordered or equal
- >
- >
- >Unordered means one or both operands is a NAN.
-
- Could someone summarize the rationale for introducing these new operators.
- If arithmetic conforms to IEEE-754 then the existing comparison operators
- should deal with unordered quantities. You can view IEEE-754 as a collateral
- standard: if a translator conforms both to the C++ standard and to IEEE-754
- then IEEE-754 defines the behaviour of certain operators in circumstances
- where the (as yet non-existent) C++ standard leaves them undefined.
-
- Chris Flatters
- cflatter@nrao.edu
-
-