1
Fork 0

Rollup merge of #108099 - matthiaskrgr:str_to_char, r=GuillaumeGomez

use chars instead of strings where applicable
This commit is contained in:
Matthias Krüger 2023-02-16 17:51:26 +01:00 committed by GitHub
commit 09a2267e1d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View file

@ -344,7 +344,7 @@ fn preprocess_link(link: &str) -> String {
let link = link.strip_suffix("()").unwrap_or(link);
let link = link.strip_suffix("{}").unwrap_or(link);
let link = link.strip_suffix("[]").unwrap_or(link);
let link = if link != "!" { link.strip_suffix("!").unwrap_or(link) } else { link };
let link = if link != "!" { link.strip_suffix('!').unwrap_or(link) } else { link };
strip_generics_from_path(link).unwrap_or_else(|_| link.to_string())
}