Closed Bug 440779 Opened 16 years ago Closed 16 years ago

JS_NewDouble oddness in nsJSEnvironment.cpp

Categories

(Core :: DOM: Core & HTML, defect)

Other Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: jorendorff, Assigned: jorendorff)

References

Details

Attachments

(1 file)

Both hits for JS_NewDouble in dom/src/base/nsJSEnvironment.cpp should be changed to use JS_NewNumberValue instead.

http://mxr.mozilla.org/mozilla-central/source/dom/src/base/nsJSEnvironment.cpp#2733

Background -- JS_NewDouble has a long-undocumented API surprise, now described in a big red warning box here: http://developer.mozilla.org/en/docs/JS_NewDouble

It turns out most places where it's being used are just a bit broken, including one place in SpiderMonkey itself (d'oh!).  The function is being deprecated (bug 435288).
Assignee: nobody → jorendorff
Status: NEW → ASSIGNED
Attachment #326001 - Flags: review?(jst)
Blocks: 435288
Severity: minor → normal
Attachment #326001 - Flags: superreview+
Attachment #326001 - Flags: review?(jst)
Attachment #326001 - Flags: review+
Pushed http://hg.mozilla.org/mozilla-central/index.cgi/rev/c97f9b41e9af
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: