From 20282c1b20bb1ce196a3addc9f681cf6cf81feb9 Mon Sep 17 00:00:00 2001 From: Jacob Pratt Date: Sun, 19 Feb 2023 04:17:58 +0000 Subject: Reduce limit on `macro_rules!` diagnostic --- compiler/rustc_parse/src/parser/item.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/rustc_parse/src/parser') diff --git a/compiler/rustc_parse/src/parser/item.rs b/compiler/rustc_parse/src/parser/item.rs index 3e3399d05c9..f164bb330f3 100644 --- a/compiler/rustc_parse/src/parser/item.rs +++ b/compiler/rustc_parse/src/parser/item.rs @@ -459,7 +459,7 @@ impl<'a> Parser<'a> { // Maybe the user misspelled `macro_rules` (issue #91227) if self.token.is_ident() && path.segments.len() == 1 - && edit_distance("macro_rules", &path.segments[0].ident.to_string(), 3) + && edit_distance("macro_rules", &path.segments[0].ident.to_string(), 2) .is_some() { err.span_suggestion( -- cgit 1.4.1-3-g733a5