mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-23 05:03:21 +00:00
Ignore mix of {,non-}sugared doc in doc_markdown
This commit is contained in:
parent
81b0efa094
commit
9881b15822
2 changed files with 14 additions and 0 deletions
|
@ -126,6 +126,11 @@ pub fn check_attrs<'a>(cx: &EarlyContext, valid_idents: &[String], attrs: &'a [a
|
||||||
spans.extend_from_slice(¤t_spans);
|
spans.extend_from_slice(¤t_spans);
|
||||||
doc.push_str(¤t);
|
doc.push_str(¤t);
|
||||||
}
|
}
|
||||||
|
} else if let Some(name) = attr.name() {
|
||||||
|
// ignore mix of sugared and non-sugared doc
|
||||||
|
if name == "doc" {
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -144,3 +144,12 @@ fn four_quotes() {
|
||||||
/// [NIST SP 800-56A, revision 2]:
|
/// [NIST SP 800-56A, revision 2]:
|
||||||
/// https://github.com/Manishearth/rust-clippy/issues/902#issuecomment-261919419
|
/// https://github.com/Manishearth/rust-clippy/issues/902#issuecomment-261919419
|
||||||
fn issue_902_comment() {}
|
fn issue_902_comment() {}
|
||||||
|
|
||||||
|
#[cfg_attr(feature = "a", doc = " ```")]
|
||||||
|
#[cfg_attr(not(feature = "a"), doc = " ```ignore")]
|
||||||
|
/// fn main() {
|
||||||
|
/// let s = "localhost:10000".to_string();
|
||||||
|
/// println!("{}", s);
|
||||||
|
/// }
|
||||||
|
/// ```
|
||||||
|
fn issue_1469() {}
|
||||||
|
|
Loading…
Reference in a new issue