Closed
Bug 1820951
Opened 2 years ago
Closed 1 year ago
Revisit DevToolsUtils.hasSafeGetter condition
Categories
(DevTools :: General, task)
DevTools
General
Tracking
(firefox115 fixed)
RESOLVED
FIXED
115 Branch
Tracking | Status | |
---|---|---|
firefox115 | --- | fixed |
People
(Reporter: arai, Assigned: arai)
References
Details
Attachments
(2 files)
DevToolsUtils.hasSafeGetter
seems to assume that the getter with native function is "safe"
/**
* Determines if a descriptor has a getter which doesn't call into JavaScript.
*
* @param Object desc
* The descriptor to check for a safe getter.
* @return Boolean
* Whether a safe getter was found.
*/
exports.hasSafeGetter = function(desc) {
...
return fn?.callable && fn?.class == "Function" && fn?.script === undefined;
bug 1806598 changed the other place not to assume native getter is safe,
and also bug 1805288 is going to change XPCOMUtils.defineLazyGetter
to use native function.
DevToolsUtils.hasSafeGetter
should be updated to follow the changes.
Assignee | ||
Comment 1•2 years ago
|
||
Depends on D175092
Thanks a lot for taking care of this
It makes a lot of sense to share the same pattern between eager evaluation and "safe getters" in object preview
Updated•1 year ago
|
Assignee: nobody → arai.unmht
Attachment #9327862 -
Attachment description: WIP: Bug 1820951 - Implement DevToolsUtils.hasSafeGetter based on explicit allowlist and DebuggerObject.prototype.isNativeGetterWithJitInfo. r?nchevobbe! → Bug 1820951 - Implement DevToolsUtils.hasSafeGetter based on explicit allowlist and DebuggerObject.prototype.isNativeGetterWithJitInfo. r?nchevobbe!
Status: NEW → ASSIGNED
Updated•1 year ago
|
Attachment #9327862 -
Attachment description: Bug 1820951 - Implement DevToolsUtils.hasSafeGetter based on explicit allowlist and DebuggerObject.prototype.isNativeGetterWithJitInfo. r?nchevobbe! → Bug 1820951 - Part 1: Implement DevToolsUtils.hasSafeGetter based on explicit allowlist and DebuggerObject.prototype.isNativeGetterWithJitInfo. r?nchevobbe!
Assignee | ||
Comment 3•1 year ago
|
||
Depends on D175093
Pushed by arai_a@mac.com:
https://hg.mozilla.org/integration/autoland/rev/f86da5e77878
Part 1: Implement DevToolsUtils.hasSafeGetter based on explicit allowlist and DebuggerObject.prototype.isNativeGetterWithJitInfo. r=nchevobbe,devtools-reviewers
https://hg.mozilla.org/integration/autoland/rev/cb3f2eb3e0db
Part 2: Add tests. r=nchevobbe,devtools-reviewers
Comment 5•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/f86da5e77878
https://hg.mozilla.org/mozilla-central/rev/cb3f2eb3e0db
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
status-firefox115:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 115 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•