[Webkit-unassigned] [Bug 89751] Refactoring RenderTable.cpp for code re-usability

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jun 22 07:37:03 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=89751





--- Comment #4 from Julien Chaffraix <jchaffraix at webkit.org>  2012-06-22 07:37:02 PST ---
(From update of attachment 148985)
View in context: https://bugs.webkit.org/attachment.cgi?id=148985&action=review

> Source/WebCore/ChangeLog:3
> +        Refactoring RenderTable.cpp for code re-usability

This is a pretty bad name for a bug as it describes in no-way what you are doing.

I would rather rename it to something like (see below why):
* Change RenderTable sections' iterations to use the helper functions
* Unify RenderTable sections' iterations

> Source/WebCore/rendering/RenderTable.cpp:1000
> +    if (RenderTableSection* section = bottomSection()) {

This is definitely a good change. However if we are to use the helper more, I would just go ahead and kill a lot the following anti-pattern as part of this change:

for (RenderObject* child = firstChild(); child; child = child->nextSibling()) {
    if (child->isTableSection()) {
        ....
    }
}

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list