diff --git a/cli/tools/lint/ast_buffer/selector.rs b/cli/tools/lint/ast_buffer/selector.rs index 11284e8c04..d680499d0c 100644 --- a/cli/tools/lint/ast_buffer/selector.rs +++ b/cli/tools/lint/ast_buffer/selector.rs @@ -295,26 +295,17 @@ impl SelectorMatcher for Elem { #[derive(Debug, PartialEq)] struct Selector { - // short circuit if the selecor cannot match - never: bool, parts: Vec, } impl Selector { fn new() -> Self { - Self { - never: false, - parts: vec![], - } + Self { parts: vec![] } } } impl SelectorMatcher for Selector { fn matches(&mut self, offset: usize) -> bool { - if self.never { - return false; - } - self.parts.iter().all(|part| match part { SelPart::Wildcard => todo!(), SelPart::Elem(_) => todo!(),