about summary refs log tree commit diff
path: root/src/librustdoc/html/render
diff options
context:
space:
mode:
authorTor Hovland <tor+github@hovland.co>2021-04-18 17:30:04 +0200
committerTor Hovland <tor.hovland@bekk.no>2021-04-18 18:02:08 +0200
commitc975fe25e4b5756b03033e4819a5c5044ca353f2 (patch)
tree9386c531ea39473b7d785b60c10c64fb2f523d77 /src/librustdoc/html/render
parente2a77b3d46e09a263fbba0ad7b964781659e6f40 (diff)
downloadrust-c975fe25e4b5756b03033e4819a5c5044ca353f2.tar.gz
rust-c975fe25e4b5756b03033e4819a5c5044ca353f2.zip
Put attrs in a Box for memory efficiency.
Diffstat (limited to 'src/librustdoc/html/render')
-rw-r--r--src/librustdoc/html/render/print_item.rs2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index 045ff5b4b89..d941095e5e1 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -285,8 +285,6 @@ fn item_module(w: &mut Buffer, cx: &Context<'_>, item: &clean::Item, items: &[cl
                 let (stab, stab_tags) = if let (Some(def_id), Some(attrs)) =
                     (import.source.did, import.source.attrs.clone())
                 {
-                    let attrs = Box::new(attrs);
-
                     // Just need an item with the correct def_id and attrs
                     let import_item = clean::Item { def_id, attrs, ..myitem.clone() };