Closed
Bug 1462741
Opened 6 years ago
Closed 5 years ago
Function.prototype.toString() is not displayed as a native function
Categories
(Core :: JavaScript: Standard Library, defect)
Core
JavaScript: Standard Library
Tracking
()
RESOLVED
FIXED
mozilla66
Tracking | Status | |
---|---|---|
firefox66 | --- | fixed |
People
(Reporter: anba, Assigned: evilpie)
References
(Blocks 1 open bug)
Details
Attachments
(2 files, 2 obsolete files)
https://github.com/tc39/test262/blob/master/test/built-ins/Function/prototype/toString/well-known-intrinsic-object-functions.js expects that |Function.prototype.toString()| returns the string representation of a native function. Test case: --- print(Function.prototype.toString()); --- Expected: "function () {\n [native code]\n}" Actual: "function () {\n}"
Assignee | ||
Comment 1•6 years ago
|
||
I wonder if this means that we can make Function.prototype a real native function, instead of an interpreted function: https://searchfox.org/mozilla-central/rev/3fdc51e66c9487b39220ad58dcee275fca070ccd/js/src/vm/JSFunction.cpp#857
Assignee | ||
Comment 2•6 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=f81db683e726f75a7af149cf6f982e24c418e3cb
Assignee | ||
Comment 3•6 years ago
|
||
Interesting behaviour change from this: Function.prototype.{arguments, caller} now throw, because it's a native (built-in) function. Chrome also behaves like this, so it's probably web-compatible.
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → evilpies
Assignee | ||
Comment 4•6 years ago
|
||
Assignee | ||
Comment 5•6 years ago
|
||
Various debugger tests were observing Function.prototype.
Assignee | ||
Comment 6•5 years ago
|
||
Assignee | ||
Comment 7•5 years ago
|
||
Depends on D14704
Assignee | ||
Updated•5 years ago
|
Attachment #9030018 -
Attachment is obsolete: true
Assignee | ||
Updated•5 years ago
|
Attachment #9030019 -
Attachment is obsolete: true
Pushed by evilpies@gmail.com: https://hg.mozilla.org/integration/autoland/rev/7d987ede1c79 Make Function.prototype a native function. r=jorendorff https://hg.mozilla.org/integration/autoland/rev/f23ff3309649 Update tests. r=jorendorff
Comment 10•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/7d987ede1c79 https://hg.mozilla.org/mozilla-central/rev/f23ff3309649
Comment 11•5 years ago
|
||
Pushed by evilpies@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/faac12c6cb61 Enable test262 test. r=me
Assignee | ||
Updated•5 years ago
|
Keywords: leave-open
Comment 12•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/faac12c6cb61
Status: NEW → RESOLVED
Closed: 5 years ago
status-firefox66:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla66
Updated•5 years ago
|
status-firefox62:
affected → ---
You need to log in
before you can comment on or make changes to this bug.
Description
•