Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 547e70e42ef9715daf53fc649da6899a1f0096ad
      
https://github.com/WebKit/WebKit/commit/547e70e42ef9715daf53fc649da6899a1f0096ad
  Author: Matthieu Dubet <[email protected]>
  Date:   2023-04-14 (Fri, 14 Apr 2023)

  Changed paths:
    M Source/WebCore/dom/SelectorQuery.cpp
    M Source/WebCore/style/RuleSetBuilder.cpp

  Log Message:
  -----------
  Avoid unnecessary copy of CSSSelectorList with non nested style rule
https://bugs.webkit.org/show_bug.cgi?id=255443
rdar://108037598

Reviewed by Antti Koivisto.

resolveNestingParent() creates a copy of the selector list
and resolves it.
We should avoid calling it altogether when it's unnecessary
(top level and no & selector).

* Source/WebCore/dom/SelectorQuery.cpp:
(WebCore::SelectorQueryCache::add):
* Source/WebCore/style/RuleSetBuilder.cpp:
(WebCore::Style::RuleSetBuilder::resolveSelectorListWithNesting):

Canonical link: https://commits.webkit.org/262953@main


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to