Skip to content

Offline, privacy-first grammar checker. Fast, open-source, Rust-powered

fix(linting): don't join "out guesses" to "outguesses" (#4863)

yi111d440ad4b6d74
diff --git a/harper-core/src/linting/disjoint_prefixes.rs b/harper-core/src/linting/disjoint_prefixes.rs
index 226eaae0e..a3f866b76 100644
--- a/harper-core/src/linting/disjoint_prefixes.rs
+++ b/harper-core/src/linting/disjoint_prefixes.rs
@@ -11,7 +11,7 @@ pub struct DisjointPrefixes<D> {
}
// Known false positives not to join to these prefixes:
-const OUT_EXCEPTIONS: &[&str] = &["boxes", "facing", "live", "numbers", "playing"];
+const OUT_EXCEPTIONS: &[&str] = &["boxes", "facing", "guesses", "live", "numbers", "playing"];
const OVER_EXCEPTIONS: &[&str] = &["all", "joy", "long", "night", "reading", "steps", "time"];
const UNDER_EXCEPTIONS: &[&str] = &["development", "mine"];
const UP_EXCEPTIONS: &[&str] = &["loading", "right", "state", "time", "trend"];
@@ -216,6 +216,14 @@ mod tests {
);
}
+ #[test]
+ fn dont_join_out_guesses_4853() {
+ assert_no_lints(
+ "Leave out guesses about how people felt.",
+ DisjointPrefixes::new(FstDictionary::curated()),
+ );
+ }
+
#[test]
fn fix_title_case_hyphenated_to_joined_4381() {
assert_suggestion_result(