Peformance is a good question. My guess would be that it'd perform somewhere between a virtual function and plain function call. I'd definitely want to run some numbers to know for sure, but it's not much different from using function pointers in C (as far as I understand rust anyway).
- Joel On Wed, Jun 12, 2013 at 10:14 PM, Boris Zbarsky <[email protected]> wrote: > On 6/12/13 6:06 PM, Joel Feenstra wrote: > >> What if the boxes and flow contexts were given a style accessor closure by >> the box/flow builder. >> > > How well would this perform? At least in Gecko, getting styles is > something that happens a _lot_ and is a notorious performance hotspot > during layout... > > > That way we wouldn't need special types >> of boxes for first line or first letter or any other special cases. >> > > Right, I don't think we need special types of boxes here. > > > -Boris > ______________________________**_________________ > dev-servo mailing list > [email protected] > https://lists.mozilla.org/**listinfo/dev-servo<https://lists.mozilla.org/listinfo/dev-servo> > _______________________________________________ dev-servo mailing list [email protected] https://lists.mozilla.org/listinfo/dev-servo

