about summary refs log tree commit diff
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2021-03-22 09:08:58 -0700
committerManish Goregaokar <manishsmail@gmail.com>2021-04-12 08:45:45 -0700
commit846a4e9b5cc49ab42a62a15cd2813b0be34fb868 (patch)
treef6d5a2c470e312b72e2c9531220f3f81b2c85e74
parente2f59f41f91ad43492e8a48b92307c9a87b2294e (diff)
downloadrust-846a4e9b5cc49ab42a62a15cd2813b0be34fb868.tar.gz
rust-846a4e9b5cc49ab42a62a15cd2813b0be34fb868.zip
Update src/librustdoc/html/render/print_item.rs
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
-rw-r--r--src/librustdoc/html/render/print_item.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index 6272790740e..d5a5ecd3e88 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -1306,7 +1306,7 @@ fn render_union(
     write!(w, " {{\n{}", tab);
     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 toggle = should_hide_fields(count_fields);
     if toggle {