[webkit-reviews] review granted: [Bug 224248] Wasted vector capacity under RuleFeatureSet::collectFeatures() : [Attachment 425330] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Apr 7 09:59:28 PDT 2021
Devin Rousso <drousso at apple.com> has granted Simon Fraser (smfr)
<simon.fraser at apple.com>'s request for review:
Bug 224248: Wasted vector capacity under RuleFeatureSet::collectFeatures()
https://bugs.webkit.org/show_bug.cgi?id=224248
Attachment 425330: Patch
https://bugs.webkit.org/attachment.cgi?id=425330&action=review
--- Comment #2 from Devin Rousso <drousso at apple.com> ---
Comment on attachment 425330
--> https://bugs.webkit.org/attachment.cgi?id=425330
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=425330&action=review
r=me
> Source/WebCore/style/StyleScopeRuleSets.cpp:253
> + if (matchElementArray[i]) {
NIT: you could save this as `auto* matchElementItem = matchElementArray[i]` to
avoid repeated access
> Source/WebCore/style/StyleScopeRuleSets.cpp:255
> + invalidationRuleSets->uncheckedAppend({
static_cast<MatchElement>(i), *matchElementArray[i],
WTFMove(invalidationSelectorArray[i]) });
NIT: Could this be `matchElementItem.releaseNonNull()` since it's created
above?
More information about the webkit-reviews
mailing list