style: More gracefully deal with broken calls into selector matching

If this happens again, it might be worth not matching rather than
potentially crashing. Though I guess crashing is a very good way getting
it reported soon...

Differential Revision: https://phabricator.services.mozilla.com/D178921
This commit is contained in:
Emilio Cobos Álvarez 2023-05-24 13:24:14 +00:00 committed by Martin Robinson
parent b329d547be
commit ad81122fcf

View file

@ -319,12 +319,14 @@ where
}
}
},
_ => {
ref other => {
debug_assert!(
false,
"Used MatchingMode::ForStatelessPseudoElement \
in a non-pseudo selector"
in a non-pseudo selector {:?}",
other
);
return false;
},
}