fix: metadata-collector listing lints when config documents include comma
This commit is contained in:
parent
0bf0b88035
commit
9dcf92649c
2 changed files with 4 additions and 1 deletions
|
|
@ -550,7 +550,7 @@ define_Conf! {
|
|||
/// Lint: PUB_UNDERSCORE_FIELDS
|
||||
///
|
||||
/// Lint "public" fields in a struct that are prefixed with an underscore based on their
|
||||
/// exported visibility; or whether they are marked as "pub".
|
||||
/// exported visibility, or whether they are marked as "pub".
|
||||
(pub_underscore_fields_behavior: PubUnderscoreFieldsBehaviour = PubUnderscoreFieldsBehaviour::PublicallyExported),
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -96,6 +96,9 @@ fn parse_config_field_doc(doc_comment: &str) -> Option<(Vec<String>, String)> {
|
|||
doc_comment.make_ascii_lowercase();
|
||||
let lints: Vec<String> = doc_comment
|
||||
.split_off(DOC_START.len())
|
||||
.lines()
|
||||
.next()
|
||||
.unwrap()
|
||||
.split(", ")
|
||||
.map(str::to_string)
|
||||
.collect();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue