Update src/librustdoc/html/render/print_item.rs
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
This commit is contained in:
parent
256e594b0a
commit
e2f59f41f9
1 changed files with 1 additions and 1 deletions
|
@ -1363,7 +1363,7 @@ fn render_struct(
|
|||
w.write_str(" {");
|
||||
let count_fields = fields
|
||||
.iter()
|
||||
.filter(|f| if let clean::StructFieldItem(..) = *f.kind { true } else { false })
|
||||
.filter(|f| matches!(clean::StructFieldItem(..) = *f.kind))
|
||||
.count();
|
||||
let has_visible_fields = count_fields > 0;
|
||||
let toggle = should_hide_fields(count_fields);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue