We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5678531 commit 2666ed6Copy full SHA for 2666ed6
clippy_config/src/conf.rs
@@ -102,7 +102,9 @@ pub fn sanitize_explanation(raw_docs: &str) -> String {
102
// Remove tags and hidden code:
103
let mut explanation = String::with_capacity(128);
104
let mut in_code = false;
105
- for line in raw_docs.lines().map(str::trim) {
+ for line in raw_docs.lines() {
106
+ let line = line.strip_prefix(' ').unwrap_or(line);
107
+
108
if let Some(lang) = line.strip_prefix("```") {
109
let tag = lang.split_once(',').map_or(lang, |(left, _)| left);
110
if !in_code && matches!(tag, "" | "rust" | "ignore" | "should_panic" | "no_run" | "compile_fail") {
0 commit comments