Derived class constructors always marked as having unknown properties
Categories
(Core :: JavaScript Engine: JIT, defect, P3)
Tracking
()
People
(Reporter: anba, Assigned: anba)
References
Details
Attachments
(2 files)
Derived class constructors created via FunWithProtoOperation
are always getting marked as having unknown properties, because CloneFunctionObjectIfNotSingleton
calls the generic SetPrototype
function:
js> dumpObject(class extends class {} { constructor() {} })
object 32844fd80f60
global 32844fd7b060 [global]
class 5559473467e8 Function
group 32844fd78850
flags: inDictionaryMode hasShapeTable
proto <unnamed function (typein:1) at 32844fd80fb0>
properties:
[Latin 1]"prototype": <Object at c79a9000550> (shape 32844fd9d970 readonly permanent slot 0)
I wonder if it's possible to replace the SetPrototype
call with JSObject::splicePrototype
(change).
Try looks green with this change applied, but I'm not sure if there are any pitfalls lurking elsewhere: https://treeherder.mozilla.org/#/jobs?repo=try&revision=cf36196aee915762335915ef2e29465c88e8ecca
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
Depends on D58803
Updated•5 years ago
|
Updated•5 years ago
|
Comment 4•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/fa3ca6fd6f40
https://hg.mozilla.org/mozilla-central/rev/ab8ec6eab00c
Comment 5•5 years ago
|
||
Since the status are different for nightly and release, what's the status for beta?
For more information, please visit auto_nag documentation.
Assignee | ||
Updated•5 years ago
|
Description
•