| Summary: | Avoid repeated is<MutableStyleProperties>() checks in StyleProperties | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||||
| Component: | CSS | Assignee: | Chris Dumez <cdumez> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | barraclough, benjamin, commit-queue, koivisto | ||||||
| Priority: | P2 | ||||||||
| Version: | 528+ (Nightly build) | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Chris Dumez
2014-10-22 12:30:53 PDT
Created attachment 240290 [details]
Patch
Comment on attachment 240290 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=240290&action=review r=me! > Source/WebCore/css/StyleProperties.cpp:114 > + for (unsigned i = 0; i < immutableOther.propertyCount(); ++i) I'd cache the propertyCount() in a local. Comment on attachment 240290 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=240290&action=review >> Source/WebCore/css/StyleProperties.cpp:114 >> + for (unsigned i = 0; i < immutableOther.propertyCount(); ++i) > > I'd cache the propertyCount() in a local. In this case, I don't think there is a performance impact as it is inlined but OK, it is good practice. Created attachment 240292 [details]
Patch
Comment on attachment 240292 [details] Patch Clearing flags on attachment: 240292 Committed r175067: <http://trac.webkit.org/changeset/175067> All reviewed patches have been landed. Closing bug. |