Firefox 3.6 is the only browser that treats the text "INF" as a number (same for the text INFINITY)

RESOLVED FIXED

Status

()

Core
JavaScript Engine
RESOLVED FIXED
6 years ago
5 years ago

People

(Reporter: jeanyce, Unassigned)

Tracking

1.9.2 Branch
x86
Windows 7
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

6 years ago
User-Agent:       Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/534.24 (KHTML, like Gecko) Chrome/11.0.696.68 Safari/534.24
Build Identifier: 3.6.17

Chrome          isNaN("INF") : true
Chrome Canary   isNaN("INF") : true
IE9             isNaN("INF") : true
IE8             isNaN("INF") : true
IE7             isNaN("INF") : true
IE6             isNaN("INF") : true
Firefox 4       isNaN("INF") : true
Firefox 3.6     isNaN("INF") : false
Firefox 2       isNaN("INF") : true

Reproducible: Always

Steps to Reproduce:
1. Type javascript:alert(isNaN("INF")) in the URL bar and press ENTER

Actual Results:  
2. Firefox 3.6 will display false
3. All other browsers display true

Expected Results:  
true (the String "INF" should not be treated like a number)
(Reporter)

Updated

6 years ago
Version: unspecified → 3.6 Branch

Updated

6 years ago
Assignee: nobody → general
Component: General → JavaScript Engine
Product: Firefox → Core
QA Contact: general → general
Version: 3.6 Branch → 1.9.2 Branch
I suspect this is wontfix unless there's a clear security or major compatibility (as in, actual major sites broken) issue here.

Comment 2

6 years ago
Firefox 3.5     isNaN("INF") : false
Firefox 3.0     isNaN("INF") : true

Comment 3

6 years ago
Just to have it documented:

Caused by bug 384244 (Firefox 3.1a2pre 2008-08-06)
http://hg.mozilla.org/mozilla-central/rev/1b24f8e54d1b

Fixed by bug 613492 (Firefox 4.0b8pre 2010-11-26)
http://hg.mozilla.org/tracemonkey/rev/222c29336422

Comment 4

6 years ago
bah the ref links is mixed up.. its 

Caused by bug 384244 (Firefox 3.1a2pre 2008-08-06)
http://hg.mozilla.org/tracemonkey/rev/222c29336422

Fixed by bug 613492 (Firefox 4.0b8pre 2010-11-26)
http://hg.mozilla.org/mozilla-central/rev/1b24f8e54d1b

Comment 5

5 years ago
This is FIXED in Fx4 (and WONTFIX in Fx3.6)
Status: UNCONFIRMED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED

Updated

5 years ago
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.