Subj : Spidermonkey: Incorrect NaN comparison To : netscape.public.mozilla.jseng From : Corey Murtagh Date : Fri May 16 2003 05:59 pm Trying this: print(Math.floor(undefined) + " " + Math.floor(undefined) == NaN) produces: NaN false So, it appears that NaN values returned by the Math functions are non comparable to the NaN constant. According to E262-3 (section 8.5): "... to ECMAScript code, all NaN values are indistinguishable from each other." I read this to mean that any of the 9007199254740990 (according to E262-3) possible NaN values should be equivalent. -- Corey Murtagh The Electric Monk "Quidquid latine dictum sit, altum viditur!" .