Refactor JSON.parse implementation to match current spec
Categories
(Core :: JavaScript Engine, task, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox121 | --- | fixed |
People
(Reporter: bthrall, Assigned: bthrall)
References
(Blocks 1 open bug)
Details
Attachments
(6 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
The JSON.parse implementation reflects the ES5 spec.
To make it easier to make changes in the future, we should refactor the implementation to reflect the current spec.
The code comments should reference the current spec section and headers.
Where possible, without hurting performance, the code structure should also reflect the algorithms in the spec (including variable names, function names, data flow, etc.).
Assignee | ||
Updated•1 year ago
|
Assignee | ||
Comment 1•1 year ago
|
||
Assignee | ||
Comment 2•1 year ago
|
||
Depends on D191774
Assignee | ||
Comment 3•1 year ago
|
||
Depends on D191775
Assignee | ||
Comment 4•1 year ago
|
||
Depends on D191776
Assignee | ||
Comment 5•1 year ago
|
||
Depends on D191777
Assignee | ||
Comment 6•1 year ago
|
||
Depends on D191778
Assignee | ||
Comment 7•1 year ago
|
||
The code structure already resembled the spec algorithms, with exceptions for performance. I did need to rename a few methods to better mach the spec, but none of the differences in variable names seemed significant enough to need updating.
Comment 9•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/28ba90bd58a2
https://hg.mozilla.org/mozilla-central/rev/7e2c4ed96bb1
https://hg.mozilla.org/mozilla-central/rev/a90002692362
https://hg.mozilla.org/mozilla-central/rev/1f12fb871f48
https://hg.mozilla.org/mozilla-central/rev/3192598920b3
https://hg.mozilla.org/mozilla-central/rev/897b39f9148a
Description
•