improve encapsulation
Created attachment 440039 [details] Patch
Created attachment 440041 [details] Patch
Created attachment 440042 [details] Patch
Created attachment 440055 [details] Patch
Created attachment 440058 [details] Patch
Created attachment 440060 [details] Patch
Created attachment 440061 [details] Patch
Created attachment 440062 [details] Patch
Committed r283508 (242476@main): <https://commits.webkit.org/242476@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 440062 [details].
<rdar://problem/83849661>
Comment on attachment 440062 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440062&action=review Noticed one small stylistic thing. > Source/WebCore/style/RuleSetBuilder.h:59 > + Vector<size_t> affectedRulePositions { }; > + RuleFeatureVector ruleFeatures { }; These braces aren’t needed. > Source/WebCore/style/RuleSetBuilder.h:63 > + Vector<DynamicContext> dynamicContextStack { }; > + > + Vector<RuleSet::DynamicMediaQueryRules> dynamicMediaQueryRules { }; These braces aren’t needed. > Source/WebCore/style/RuleSetBuilder.h:75 > + CascadeLayerName m_resolvedCascadeLayerName { }; > + HashMap<CascadeLayerName, RuleSet::CascadeLayerIdentifier> m_cascadeLayerIdentifierMap { }; These braces aren’t needed. > Source/WebCore/style/RuleSetBuilder.h:77 > + Vector<RuleSet::ResolverMutatingRule> m_collectedResolverMutatingRules { }; These braces aren’t needed.
Comment on attachment 440062 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440062&action=review >> Source/WebCore/style/RuleSetBuilder.h:59 >> + struct DynamicContext { >> + Ref<const MediaQuerySet> set; >> + Vector<size_t> affectedRulePositions { }; >> + RuleFeatureVector ruleFeatures { }; > > These braces aren’t needed. Some of the compilers in bots have failed in the past if all fields are not initialized explicitly when the struct is brace-initialized.
Comment on attachment 440062 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440062&action=review >>> Source/WebCore/style/RuleSetBuilder.h:59 >>> + RuleFeatureVector ruleFeatures { }; >> >> These braces aren’t needed. > > Some of the compilers in bots have failed in the past if all fields are not initialized explicitly when the struct is brace-initialized. Does that really apply here or not?
> Does that really apply here or not? Seems so, see https://bugs.webkit.org/show_bug.cgi?id=231236 (class members here don't need them)
(In reply to Antti Koivisto from comment #14) > > Does that really apply here or not? > > Seems so, see https://bugs.webkit.org/show_bug.cgi?id=231236 > > (class members here don't need them) Thanks! I appreciate learning about this.