Skip to content

Commit

Permalink
metadata: Encode attrs for foreign items.
Browse files Browse the repository at this point in the history
Related to #19649 and #16289
  • Loading branch information
tomjakubowski committed Dec 20, 2014
1 parent 8f51ad2 commit 44f6f52
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/librustc/metadata/encoder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1478,6 +1478,7 @@ fn encode_info_for_foreign_item(ecx: &EncodeContext,
if abi == abi::RustIntrinsic {
encode_inlined_item(ecx, rbml_w, IIForeignRef(nitem));
}
encode_attributes(rbml_w, &*nitem.attrs);
encode_symbol(ecx, rbml_w, nitem.id);
}
ast::ForeignItemStatic(_, mutbl) => {
Expand All @@ -1488,6 +1489,7 @@ fn encode_info_for_foreign_item(ecx: &EncodeContext,
}
encode_bounds_and_type(rbml_w, ecx,
&lookup_item_type(ecx.tcx,local_def(nitem.id)));
encode_attributes(rbml_w, &*nitem.attrs);
encode_symbol(ecx, rbml_w, nitem.id);
encode_name(rbml_w, nitem.ident.name);
}
Expand Down

0 comments on commit 44f6f52

Please sign in to comment.