It holds a function pointer to the HeapSizeOf::heap_size_of_children()
implementation corresponding to that IDL interface.
This removes the need for a clumsly TypeId-based match expression in the
former heap_size_of_eventtarget() function.
Source-Repo: https://github.com/servo/servo
Source-Revision: 5a0a91eba794af027723051c7f039cb22088aa65
This frees us forever from caring about maintaining these enums. The last commit removes their use from the initialisation of interface objects derived from Node.
Source-Repo: https://github.com/servo/servo
Source-Revision: 32daa17d5cbcad02db0713e21e52410cdc60480e
Also adds HeapSizeOf implementations/derive for some types. I've used "Cannot calculate Heap size" as a reason everywhere, because my imagination is rather limited. If you'd like me to change this message for specific types, please write something like this: "Trusted - Cannot calculate Heap size for Trusted" so that it would be easier for me to replace them through a script :)
Source-Repo: https://github.com/servo/servo
Source-Revision: a03616f379c255cc6c9b6e1d04dd7d98bd9926ce
…s for frame treese in script tasks.
This underreports by a significant amount, since only Document, Window and CharacterData (ie. text) nodes are fully represented. That being said, every HTML element in the tree is measured, but only counted as a Node. It's easy to improve this, it just requires adding the appropriate HeapSizeOf derives and increasing the granularity of `measure_memory_for_eventtarget`. google.com shows a dom-tree value of 0.24 MB for me at the moment.
r? @nnethercote
Source-Repo: https://github.com/servo/servo
Source-Revision: 84e25befdd97cf74fb00707dbe150d59d980e977