Revert "LibWeb/CSS: Keep invalid parts of <forgiving-selector-list>s around"

This reverts commit 698dd600f2.

This caused multiple tests to crash on macOS:
https://github.com/LadybirdBrowser/ladybird/pull/2317#issuecomment-2474725826
This commit is contained in:
Andreas Kling 2024-11-13 21:37:34 +01:00
commit 2a5dbedad4
Notes: github-actions[bot] 2024-11-13 20:39:08 +00:00
8 changed files with 3 additions and 110 deletions

View file

@ -764,9 +764,6 @@ static inline bool matches(CSS::Selector::SimpleSelector const& component, Optio
// :is() is handled already, by us replacing it with :is() directly, so if we
// got here, it's :scope.
return matches_pseudo_class(CSS::Selector::SimpleSelector::PseudoClassSelector { .type = CSS::PseudoClass::Scope }, style_sheet_for_rule, element, shadow_host, scope, selector_kind);
case CSS::Selector::SimpleSelector::Type::Invalid:
// Invalid selectors never match
return false;
}
VERIFY_NOT_REACHED();
}