Make it possible to implement several WebIDL interfaces using the same native class

RESOLVED FIXED in mozilla21

Status

()

defect
RESOLVED FIXED
7 years ago
4 months ago

People

(Reporter: Ehsan, Assigned: bzbarsky)

Tracking

(Blocks 1 bug)

Trunk
mozilla21
x86
macOS
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Reporter

Description

7 years ago
Currently this seems to be impossible due to the PrototypeIdMap, and it looks like that's Ben's fault.  ;-)

You can see the resulting ugliness in my upcoming patch to bug 836599.
So turns out we had code that tried to make this work... it was just buggy.  Patch coming up.
Assignee: nobody → bzbarsky
Whiteboard: [need review]
Blocks: 839116
Comment on attachment 711379 [details] [diff] [review]
Patch and use of the new ability for sharedlist

Review of attachment 711379 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/bindings/Configuration.py
@@ +60,3 @@
>              otherDescriptors = [d for d in self.descriptors
> +                                if d.nativeType == nativeType]
> +            descriptor.unsharedImplementation = len(otherDescriptors) == 1

Maybe:

any(d.nativeType == descriptor.nativeType and d != descriptor for d in self.descriptors)?
Attachment #711379 - Flags: review?(peterv) → review+
> Maybe:

I'd need a negation of that, so I wrote it like so:

            descriptor.unsharedImplementation = all(
                d.nativeType != descriptor.nativeType or d == descriptor
                for d in self.descriptors)
https://hg.mozilla.org/integration/mozilla-inbound/rev/d32064860f36
Flags: in-testsuite+
Whiteboard: [need review]
Target Milestone: --- → mozilla21
https://hg.mozilla.org/mozilla-central/rev/d32064860f36
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Reporter

Updated

6 years ago
Blocks: 836599
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.