Box TypedefItem, ImplItem, AssocTypeItem variants of ItemKind
This reduces ItemKind size from 224 bytes to 160 bytes.
This commit is contained in:
parent
0bf65c7c92
commit
96c051fd07
10 changed files with 37 additions and 37 deletions
|
@ -1160,7 +1160,7 @@ fn render_deref_methods(
|
|||
.items
|
||||
.iter()
|
||||
.find_map(|item| match *item.kind {
|
||||
clean::AssocTypeItem(ref t, _) => Some(match *t {
|
||||
clean::AssocTypeItem(box ref t, _) => Some(match *t {
|
||||
clean::Typedef { item_type: Some(ref type_), .. } => (type_, &t.type_),
|
||||
_ => (&t.type_, &t.type_),
|
||||
}),
|
||||
|
@ -2054,7 +2054,7 @@ fn sidebar_deref_methods(
|
|||
debug!("found Deref: {:?}", impl_);
|
||||
if let Some((target, real_target)) =
|
||||
impl_.inner_impl().items.iter().find_map(|item| match *item.kind {
|
||||
clean::AssocTypeItem(ref t, _) => Some(match *t {
|
||||
clean::AssocTypeItem(box ref t, _) => Some(match *t {
|
||||
clean::Typedef { item_type: Some(ref type_), .. } => (type_, &t.type_),
|
||||
_ => (&t.type_, &t.type_),
|
||||
}),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue