Summary: | Use the new is<>() / downcast<>() for ShadowRoot and StyledElement | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||
Component: | DOM | Assignee: | Chris Dumez <cdumez> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | commit-queue | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Bug Depends on: | 137056 | ||||||
Bug Blocks: | |||||||
Attachments: |
|
Description
Chris Dumez
2014-09-28 16:11:15 PDT
Created attachment 238830 [details]
Patch
Comment on attachment 238830 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=238830&action=review > Source/WebCore/css/StyleResolver.cpp:391 > + m_styledElement = element && is<StyledElement>(element) ? downcast<StyledElement>(element) : nullptr; I’m not going to comment on every one, since this is the same issue as in other patches. There is no need for the null check here since the is<StyledElement> function works fine on null, returning false. And the downcast should be done on *element, with a & before downcast. This pattern repeats throughout this patch in variants. Comment on attachment 238830 [details] Patch Clearing flags on attachment: 238830 Committed r174069: <http://trac.webkit.org/changeset/174069> All reviewed patches have been landed. Closing bug. |