Count consecutive direct adjacent selectors.

The maxDirectAdjacentSelectors counter in RuleFeatureSet should only count
the maximum number of consecutive direct adjacent combinators. The number is
used to invalidate style for sibling trees.

For instance a selector like "div+div div+div" only needs to invalidate a
single sibling tree.

When a different combinator is encountered, store the number of consecutive
direct adjacent combinators seen and reset the counter; instead of counting
all direct adjacent combinators in the selector.

R=ojan
BUG=340866

Review URL: https://codereview.chromium.org/155283002

git-svn-id: svn://svn.chromium.org/blink/trunk@166468 bbb929c8-8fbe-4397-9dbb-9b2b20218538
3 files changed
tree: 2bc202bb025fccaa3761e449f672bface1ea689d
  1. third_party/