Closed Bug 1644160 Opened 5 years ago Closed 5 years ago

Proxy Support for Private Fields

Categories

(Core :: JavaScript Engine, task, P2)

task

Tracking

()

RESOLVED FIXED
81 Branch
Tracking Status
firefox81 --- fixed

People

(Reporter: mgaudet, Assigned: mgaudet)

References

(Depends on 1 open bug)

Details

Attachments

(6 files)

Private fields have some complicated (for the engine to implement) semantics.

The implementation I have with my current patches adds a hidden expando to proxies to support adding private fields to them

In the Chome(/Edge Beta) devtools, when you stamp a private field onto a proxy, you can inspect it. I think we'll need to open a bug later to do the same thing.

Assignee: nobody → mgaudet
Status: NEW → ASSIGNED
  • CrossOriginWrappers
  • A variety DOM objects (including window, and window's prototype chain)
  • Xray wrappers

I am seeking advice with this for pointers on how to test other proxy types
I think am aware of:

  • Cross Process Object Wrappers

as well as those I am not aware of.

Depends on D83511

Depends on: 1652868
Pushed by mgaudet@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/598d65b8afb5 Initial Proxy Support for Private Fields r=jorendorff https://hg.mozilla.org/integration/autoland/rev/3c88625982cf Support private fields that traverse CCWs r=jorendorff https://hg.mozilla.org/integration/autoland/rev/09df89442319 Support DeadObjectProxies r=jorendorff https://hg.mozilla.org/integration/autoland/rev/bc43898badcd Ensure TypedObjects cannot have private fields added r=jorendorff https://hg.mozilla.org/integration/autoland/rev/ce53b1934083 Use DOM Proxy Expando to hold private fields, rather than allocating Proxy Expando r=jorendorff
Keywords: leave-open
Depends on: 1653980
Flags: needinfo?(mgaudet)

So, Tom did mention on IRC that it's not -amazing- that we're increasing the number of slots on DOM proxies; I tend to agree, but don't think it's worth blocking landing this. AWSY results are fairly inconclusive.

Pushed by mgaudet@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/49b15ed562b9 Initial Proxy Support for Private Fields r=jorendorff https://hg.mozilla.org/integration/autoland/rev/b5648f412d71 Support private fields that traverse CCWs r=jorendorff https://hg.mozilla.org/integration/autoland/rev/1feadd426f1d Support DeadObjectProxies r=jorendorff https://hg.mozilla.org/integration/autoland/rev/a8ee2ca60605 Ensure TypedObjects cannot have private fields added r=jorendorff https://hg.mozilla.org/integration/autoland/rev/ab9768a4a9f3 Use DOM Proxy Expando to hold private fields, rather than allocating Proxy Expando r=jorendorff
Depends on: 1654278
Depends on: 1654308
Depends on: 1654851
Regressions: 1654472
Depends on: 1655443
Attachment #9163600 - Attachment description: Bug 1644160 - Add test cases for various DOM related classes r?jorendorff!,peterv! → Bug 1644160 - Add test cases for various DOM related classes r?jorendorff!
Keywords: leave-open
Pushed by mgaudet@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9f4aef254bea Add test cases for various DOM related classes r=jorendorff
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → 81 Branch
Blocks: 1656276
Regressions: 1658070
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: