Closed Bug 1367791 Opened 3 years ago Closed 3 years ago

Constrain toFixed precision to 0 <= n <= 100

Categories

(Core :: JavaScript Engine, enhancement)

enhancement
Not set

Tracking

()

RESOLVED FIXED
mozilla56
Tracking Status
firefox56 --- fixed

People

(Reporter: shu, Assigned: shu)

Details

Attachments

(1 file)

Small normative changed to toFixed that reached consensus in May TC39. We currently accept -20 <= n <= 100.

https://github.com/tc39/ecma262/pull/857
Due to normative change in spec.
Comment on attachment 8877348 [details] [diff] [review]
Constrain Number.prototype.toFixed precision to be 0 <= p <= 100.

test262 will have a test for this with the next sync.
Attachment #8877348 - Flags: review?(jorendorff)
Assignee: nobody → shu
Attachment #8877348 - Flags: review?(jorendorff) → review+
Pushed by shu@rfrn.org:
https://hg.mozilla.org/integration/mozilla-inbound/rev/03533ecbc1af
Constrain Number.prototype.toFixed precision to be 0 <= p <= 100. (r=jorendorff)
https://hg.mozilla.org/mozilla-central/rev/03533ecbc1af
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in before you can comment on or make changes to this bug.