Closed Bug 1083591 Opened 10 years ago Closed 10 years ago

We don't correctly codegen stringifiers and jsonifiers on non-concrete interfaces

Categories

(Core :: DOM: Core & HTML, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla36

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(1 file)

That block in Configuration.py is in with the named/indexed prop stuff, but that affects the JSClass, so is only done for concrete interfaces, whereas stringifier/jsonifier makes sense on all interfaces, since it just corresponds to methods on the prototype.
Blocks: 1082663
Comment on attachment 8505886 [details] [diff] [review]
Support stringifiers and jsonifiers on non-concrete Web IDL interfaces as well, since they make sense there

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

::: dom/bindings/Configuration.py
@@ +334,5 @@
>                      addOperation('Stringifier', m)
>                  if m.isMethod() and m.isJsonifier():
>                      addOperation('Jsonifier', m)
> +
> +        if self.concrete:

So now we loop twice, not sure if we care. But if we do, you could use one loop and continue here.
Attachment #8505886 - Flags: review?(peterv) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/e82fd502119c and then https://hg.mozilla.org/integration/mozilla-inbound/rev/6f5ba08ca1b9 to fix the resulting bustage; that's what I get for testing this on _top_ of bug 1082663's patch.
Target Milestone: --- → mozilla36
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.