BigInt shouldn't get the legacy fallback behaviour in Object.prototype.toString

RESOLVED FIXED in Firefox 62

Status

()

defect
RESOLVED FIXED
Last year
Last year

People

(Reporter: anba, Assigned: terpri)

Tracking

(Blocks 1 bug)

Trunk
mozilla62
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox62 fixed)

Details

Attachments

(1 attachment)

Test case:
---
delete BigInt.prototype[Symbol.toStringTag];
assertEq(Object.prototype.toString.call(BigInt(0)), "[object Object]");
---

Expected: Test passes
Actual: Object.prototype.toString returns "[object BigInt]"
I would suggest just changing the name in the JSClass field to "Object". Hopefully bug 1277799 is going to be fixed at some point.
Change BigInt's class name to "Object" so that the correct tag is used
when the @@toStringTag property is not a string. Remove special cases
for BigInt in GetBuiltinTagFast and GetBuiltinTagSlow.
Attachment #8981537 - Flags: review?(andrebargull)
Comment on attachment 8981537 [details] [diff] [review]
BigInt shouldn't get the legacy fallback behaviour in Object.prototype.toString.

Review of attachment 8981537 [details] [diff] [review]:
-----------------------------------------------------------------

LGTM!
Attachment #8981537 - Flags: review?(andrebargull) → review+
Attachment #8981537 - Flags: checkin+
Keywords: checkin-needed
Pushed by dluca@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/fcf6bdd122ad
BigInt shouldn't get the legacy fallback behaviour in Object.prototype.toString. r=anba
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/fcf6bdd122ad
Status: NEW → RESOLVED
Closed: Last year
Resolution: --- → FIXED
Target Milestone: --- → mozilla62
Assignee: nobody → robin
You need to log in before you can comment on or make changes to this bug.