Bug 300183
| Summary: | [Bindings] Generated `toJSNewlyCreated()` should account for descendants | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Chris Dumez <cdumez> |
| Component: | Bindings | Assignee: | Chris Dumez <cdumez> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | cdumez |
| Priority: | P2 | ||
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | |||
| Bug Blocks: | 300206, 300212, 300213, 300223, 300225, 300226, 300229, 300281, 300282, 300288, 300419, 300425, 300427, 300467 | ||
Chris Dumez
Currently, the binding can only generate a trivial version of `toJSNewlyCreated()`, which does not account for descendants. This is annoying for developers as they usually find the hard way and then they have to write custom bindings code to create the right wrapper for the right subclass type.
This patch updates the bindings generator to generate a more correct version of `toJSNewlyCreated()` when an interface has descendants and drops the custom bindings for Text.idl as proof of concept. I will then follow-up to drop more custom bindings.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Chris Dumez
Pull request: https://github.com/WebKit/WebKit/pull/51823