Skip to content

Commit 85387e1

Browse files
committed
syntax: print visibilities of foreign items
1 parent 8476419 commit 85387e1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libsyntax/print/pprust.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -457,13 +457,13 @@ pub fn print_foreign_item(s: @ps, item: &ast::foreign_item) {
457457
match item.node {
458458
ast::foreign_item_fn(ref decl, purity, ref generics) => {
459459
print_fn(s, decl, Some(purity), AbiSet::Rust(), item.ident, generics, None,
460-
ast::inherited);
460+
item.vis);
461461
end(s); // end head-ibox
462462
word(s.s, ";");
463463
end(s); // end the outer fn box
464464
}
465465
ast::foreign_item_static(ref t, m) => {
466-
head(s, "static");
466+
head(s, visibility_qualified(item.vis, "static"));
467467
if m {
468468
word_space(s, "mut");
469469
}

0 commit comments

Comments
 (0)