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

@ -506,9 +506,6 @@ void dump_selector(StringBuilder& builder, CSS::Selector const& selector, int in
case CSS::Selector::SimpleSelector::Type::Nesting:
type_description = "Nesting";
break;
case CSS::Selector::SimpleSelector::Type::Invalid:
type_description = "INVALID";
break;
}
builder.appendff("{}:", type_description);
@ -602,14 +599,6 @@ void dump_selector(StringBuilder& builder, CSS::Selector const& selector, int in
builder.appendff(", value='{}']", attribute.value);
}
if (simple_selector.type == CSS::Selector::SimpleSelector::Type::Invalid) {
auto invalid = simple_selector.value.get<CSS::Selector::SimpleSelector::Invalid>();
builder.append(" '"sv);
for (auto const& component_value : invalid.component_values)
builder.append(component_value.to_string());
builder.append("'"sv);
}
if (i != relative_selector.simple_selectors.size() - 1)
builder.append(", "sv);
}