mirror of
https://github.com/servo/servo
synced 2026-04-25 17:15:48 +02:00
This change creates a new "type bundle" trait, which holds all of the concrete implementations of the layout DOM types. The benefit here is that each implementation of a layout DOM type needs a single associated type. In addition, and most importantly, `Layout` itself only needs to parameterized over a single type (the concrete type bundle). This will make parameterizing layout a lot friendlier. The downside is that extracting the concrete type from the type bundle is a bit ugly in Rust, so the change also exposes some type aliases to make this nicer. In the future, default associated types can make things a bit simpler as well. Testing: This should not change behavior so no new tests are necessary. Signed-off-by: Martin Robinson <mrobinson@igalia.com>