Implement IndirectCrossCompartmentWrapper

RESOLVED WONTFIX

Status

()

Core
JavaScript Engine
RESOLVED WONTFIX
6 years ago
6 years ago

People

(Reporter: Bobby Holley (On Leave Until June 11th), Assigned: Bobby Holley (On Leave Until June 11th))

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [js:t])

Attachments

(1 attachment)

With Eddy's refactoring of the wrapper hierarchy over in bug 703537, there are now two types of wrappers: IndirectWrappers, which implement derived traps in terms of fundamental traps, and DirectWrappers, which forward everything explicitly.

Currently, CrossCompartmentWrapper inherits DirectWrapper, but it would be nice to have the other one too.
Whiteboard: [js:t]
Templatizing turned out to be the wrong way to go, because it meant that we'd do the cross-compartment wrapper goop twice for a single call when going through the derived traps. I've got a different strategy now.
Summary: Templatize CrossCompartmentWrapper → Implement IndirectCrossCompartmentWrapper
Created attachment 638673 [details] [diff] [review]
Introduce IndirectCrossCompartmentWrapper. v1

So, I've got this written. Unfortunately, I discovered that AbstractWrapper semantics
aren't really useful when wrapping arrays, because PropertyOp-implemented things like
.length don't work right with getPropertyDescriptor. So we rely on the special get()
behavior that calls getGeneric() to do the right thing. Lame.

Hopefully someday we'll fix the whole PropertyOp mess. In the mean time though, this
patch isn't useful to me. Posting it here for posterity.
No longer blocks: 760109
Indirect wrappers are going away in bug 803068.
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.