From 081e29c1067645751ff0b01ac90416d80f784949 Mon Sep 17 00:00:00 2001 From: Daniel Hofstetter Date: Tue, 30 Sep 2025 10:49:46 +0200 Subject: [PATCH] clippy: re-enable single_char_pattern lint --- Cargo.toml | 1 - src/uucore/src/lib/features/i18n/mod.rs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 2c6e5cdfe..e7e6261cf 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -699,7 +699,6 @@ unnested_or_patterns = "allow" implicit_hasher = "allow" struct_field_names = "allow" doc_link_with_quotes = "allow" -single_char_pattern = "allow" format_push_string = "allow" flat_map_option = "allow" from_iter_instead_of_collect = "allow" diff --git a/src/uucore/src/lib/features/i18n/mod.rs b/src/uucore/src/lib/features/i18n/mod.rs index c42d41c7e..d47f2df98 100644 --- a/src/uucore/src/lib/features/i18n/mod.rs +++ b/src/uucore/src/lib/features/i18n/mod.rs @@ -41,7 +41,7 @@ fn get_locale_from_env(locale_name: &str) -> (Locale, UEncoding) { // Naively convert the locale name to BCP47 tag format. // // See https://en.wikipedia.org/wiki/IETF_language_tag - let bcp47 = simple.replace("_", "-"); + let bcp47 = simple.replace('_', "-"); let locale = Locale::try_from_str(&bcp47).unwrap_or(DEFAULT_LOCALE); // If locale parsing failed, parse the encoding part of the