Skip to content

Commit

Permalink
Fix formatting and use Iterator::any
Browse files Browse the repository at this point in the history
  • Loading branch information
jonas-schievink committed Jul 23, 2021
1 parent b0f7aac commit c8d915e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions crates/hir_def/src/attr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -292,10 +292,10 @@ impl Attrs {
}

pub fn has_doc_hidden(&self) -> bool {
self.by_key("doc").tt_values().find(|tt| {
self.by_key("doc").tt_values().any(|tt| {
tt.delimiter_kind() == Some(DelimiterKind::Parenthesis) &&
matches!(&*tt.token_trees, [tt::TokenTree::Leaf(tt::Leaf::Ident(ident))] if ident.text == "hidden")
}).is_some()
})
}
}

Expand Down
2 changes: 1 addition & 1 deletion crates/ide_completion/src/completions/dot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ impl A {
expect![[r#"
fd pub_field u32
me pub_method() fn(&self)
"#]]
"#]],
)
}

Expand Down

0 comments on commit c8d915e

Please sign in to comment.