Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial implementation of element merge strategy
This commit supports attribute merging in component invocations by storing the attribute operations for an element in GroupedElementOperations. In `CloseElementOpcode`, we merge all of the seen operations and execute them. In principle, this work is only needed for component elements, which can have multiple sources of attributes with arbitrary merge strategies. This commit adds the GroupedElementOperations to every element, which mildly regresses performance. We plan to limit the impact to component elements, and have plans to avoid the work in all but the most dynamic scenarios. That said, this works and passes a new somewhat aggressive smoke test based on one that helped us understand the nature of the problem in Glimmer 1. Near-term work: * Avoid GroupedElementOperations for regular elements * Avoid emitting UpdatingOpcodes for static attributes on components * Extract merge strategy into ComponentManager (and possibly allow kinds of attributes to control their own merging directly) * Correctly group the operations so that invoker and invokee attributes can be properly interpreted by the merging logic.
- Loading branch information