Bug 123721

Summary: HTMLTableRowsCollection is always rooted at a HTMLTableElement.
Product: WebKit Reporter: Andreas Kling <kling>
Component: DOMAssignee: Andreas Kling <kling>
Status: RESOLVED FIXED    
Severity: Normal CC: cmarcelo, commit-queue, esprehn+autocc, gyuyoung.kim, kangil.han, kling
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch koivisto: review+

Description Andreas Kling 2013-11-04 00:14:02 PST
HTMLTableRowsCollection is always rooted at a HTMLTableElement.
Comment 1 Andreas Kling 2013-11-04 00:14:28 PST
Created attachment 215893 [details]
Patch
Comment 2 Antti Koivisto 2013-11-04 00:35:27 PST
Comment on attachment 215893 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=215893&action=review

> Source/WebCore/html/HTMLTableRowsCollection.cpp:164
> +    return rowAfter(&const_cast<HTMLTableElement&>(tableElement()), toHTMLTableRowElement(previous));

I like putting & or * inside the cast and casting to the final type.
Comment 3 Andreas Kling 2013-11-04 00:52:05 PST
Committed r158564: <http://trac.webkit.org/changeset/158564>