Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMove EventTargetTypeId/NodeTypeId to DOMClass #6615
Conversation
highfive
commented
Jul 13, 2015
hoppipolla-critic-bot
commented
Jul 13, 2015
|
Critic review: https://critic.hoppipolla.co.uk/r/5541 This is an external review system which you may optionally use for the code review of your pull request. In order to help critic track your changes, please do not make in-place history rewrites (e.g. via |
|
I presume this stored in the NodeInfo struct in Gecko. I'll need to think about this change. |
|
I don't think there's a direct equivalent in Gecko since gecko has vtables to store info about the class hierarchy. I do plan to roll other node fields into static data structures, similar to NodeInfo in gecko. Our equivalent might be fully statically allocated though. |
|
Not a big fan on the face of it... |
|
|
|
I'm really ambivalent about this change. On one hand, it reduces the size of common objects and automates one more thing, but on the other hand it adds a lot of |
|
Ditto. |
|
@michaelwu ping |
|
I think the ping was more about addressing our concerns rather than rebasing. |
|
|
|
No I was just rebasing because I had to. This is necessary for other patches I'm working on and makes more sense in context. |
|
Couldn't we introduce a new Servo-specific WebIDL extended attribute to mark interfaces that shouldn't appear in the TypeId hierarchy, to avoid NodeTypeId::Node and similar values? @michaelwu Do you want me to try to do such a thing and otherwise rebase your branch, so you can focus on your magical DOM thing? |
|
@nox I'd be happy with a solution like that. |
|
Superseded by #7606. |
michaelwu commentedJul 13, 2015
Saves 16 bytes in
Node, and 8 bytes inEventTargetobjects that aren't nodes.A number of *TypeId enums were adjusted to allow CodegenRust to automatically generate enums.