Offline, privacy-first grammar checker. Fast, open-source, Rust-powered
fix: adapt new linters
hippietraile3ed6c94f2bc
diff --git a/harper-core/src/linting/ajar.rs b/harper-core/src/linting/ajar.rsindex 3a1d2bfa8..a3ac31c27 100644--- a/harper-core/src/linting/ajar.rs+++ b/harper-core/src/linting/ajar.rs@@ -11,7 +11,7 @@ pub struct Ajar {impl Default for Ajar {fn default() -> Self {Self {- expr: SequenceExpr::word_set(&["door", "doors", "gate", "gates", "mouth", "slightly"])+ expr: SequenceExpr::word_set(["door", "doors", "gate", "gates", "mouth", "slightly"]).t_ws_h().t_aco("a").t_ws_h()@@ -23,7 +23,7 @@ impl Default for Ajar {.t_any().t_any().t_ws()- .t_set(&["containing", "contains", "full", "of"]),+ .t_set(["containing", "contains", "full", "of"]),),}}diff --git a/harper-core/src/linting/akimbo.rs b/harper-core/src/linting/akimbo.rsindex 037d3443a..76e46a28a 100644--- a/harper-core/src/linting/akimbo.rs+++ b/harper-core/src/linting/akimbo.rs@@ -11,7 +11,7 @@ pub struct Akimbo {impl Default for Akimbo {fn default() -> Self {Self {- expr: SequenceExpr::word_set(&[+ expr: SequenceExpr::word_set(["arm", "arms", "elbows", "all", "fingers", "hand", "hands", "legs", "limbs","stand", "standing", "stands", "stood",])@@ -26,7 +26,7 @@ impl Default for Akimbo {.t_any().t_any().t_ws()- .t_set(&["slice"]),+ .t_set(["slice"]),),}}diff --git a/harper-core/src/linting/ever_pronoun_rel_pronoun.rs b/harper-core/src/linting/ever_pronoun_rel_pronoun.rsindex 38a9a9d96..a1aacfc80 100644--- a/harper-core/src/linting/ever_pronoun_rel_pronoun.rs+++ b/harper-core/src/linting/ever_pronoun_rel_pronoun.rs@@ -12,7 +12,7 @@ pub struct EverPronounRelPronoun {impl Default for EverPronounRelPronoun {fn default() -> Self {Self {- expr: SequenceExpr::word_set(&[+ expr: SequenceExpr::word_set(["whatever","whenever","wherever",@@ -23,11 +23,11 @@ impl Default for EverPronounRelPronoun {.then_any_of([Box::new(SequenceExpr::aco("that").t_ws().then_any_of([Box::new(SequenceExpr::default().then_subject_pronoun()) as Box<dyn Expr>,- Box::new(WordSet::new(&[+ Box::new(WordSet::new(["I've", "we've", "you've", "he's", "she's", "it's", "they've",])),])) as Box<dyn Expr>,- Box::new(WordSet::new(&["which", "who", "whom"])),+ Box::new(WordSet::new(["which", "who", "whom"])),]),}}diff --git a/harper-core/src/linting/nail_in_coffin.rs b/harper-core/src/linting/nail_in_coffin.rsindex ac6fbd9cb..d38f79612 100644--- a/harper-core/src/linting/nail_in_coffin.rs+++ b/harper-core/src/linting/nail_in_coffin.rs@@ -15,15 +15,15 @@ pub struct NailInCoffin {impl Default for NailInCoffin {fn default() -> Self {Self {- expr: SequenceExpr::word_set(&["final", "last"])+ expr: SequenceExpr::word_set(["final", "last"]).t_ws()- .t_set(&["nail", "nails"])+ .t_set(["nail", "nails"]).t_ws().t_aco("on").t_ws().then_determiner().t_ws()- .t_set(&["coffin", "coffins"]),+ .t_set(["coffin", "coffins"]),}}}diff --git a/harper-core/src/linting/take_pride_in.rs b/harper-core/src/linting/take_pride_in.rsindex f5b72a261..dc262f9f5 100644--- a/harper-core/src/linting/take_pride_in.rs+++ b/harper-core/src/linting/take_pride_in.rs@@ -11,7 +11,7 @@ pub struct TakePrideIn {impl Default for TakePrideIn {fn default() -> Self {Self {- expr: SequenceExpr::word_set(&["take", "taken", "takes", "taking", "took"])+ expr: SequenceExpr::word_set(["take", "taken", "takes", "taking", "took"]).t_ws().then_word_seq(&["pride", "of"]).but_not(