Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!yale!cmcl2!lanl!jlg From: jlg@lanl.gov (Jim Giles) Newsgroups: comp.arch Subject: Re: Comparison operators (was: He's not the only one at it again!) Message-ID: <58995@lanl.gov> Date: 2 Aug 90 22:36:31 GMT References: <2377@crdos1.crd.ge.COM> Organization: Los Alamos Natl Lab, Los Alamos, N.M. Lines: 19 From article <2377@crdos1.crd.ge.COM>, by davidsen@crdos1.crd.ge.COM (Wm E Davidsen Jr): > [...] > When I generated a tiny implementation language I went back to := to > avoid typing mistakes, and used <> instead of != because a lot more > people could read it first time. Well, you've actually got back to a comp.arch topic. The problem here is that <> doesn't mean the same thing as !=. The first means (intuitively anyway) less-than or greater-than, while the second means not equal. Now, suppose you have two NANs: NAN1 <> NAN2 NAN1 != NAN2 The first of these conditions is false whicl the second is true. NANs are unordered (so they can't be "less-than or greater-than" each other), but they also always compare as "not equal". J. Giles