Merge pull request #20122 from chenyukang/yukang-fix-remove-parens

Remove unnecessary parens in closure
This commit is contained in:
Chayim Refael Friedman 2025-06-29 15:14:31 +00:00 committed by GitHub
commit 6df12139bc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -195,5 +195,5 @@ fn comma_wrapper(ctx: &CompletionContext<'_>) -> Option<(impl Fn(&str) -> String
matches!(prev_token_kind, SyntaxKind::COMMA | SyntaxKind::L_PAREN | SyntaxKind::PIPE);
let leading = if has_leading_comma { "" } else { ", " };
Some((move |label: &_| (format!("{leading}{label}{trailing}")), param.text_range()))
Some((move |label: &_| format!("{leading}{label}{trailing}"), param.text_range()))
}