File tree 1 file changed +3
-1
lines changed
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -1730,6 +1730,7 @@ impl Clean<Item> for hir::StructField<'_> {
1730
1730
StructFieldItem ( self . ty . clean ( cx) ) ,
1731
1731
cx,
1732
1732
) ;
1733
+ // Don't show `pub` for fields on enum variants; they are always public
1733
1734
Item { visibility : self . vis . clean ( cx) , ..what_rustc_thinks }
1734
1735
}
1735
1736
}
@@ -1742,6 +1743,7 @@ impl Clean<Item> for ty::FieldDef {
1742
1743
StructFieldItem ( cx. tcx . type_of ( self . did ) . clean ( cx) ) ,
1743
1744
cx,
1744
1745
) ;
1746
+ // Don't show `pub` for fields on enum variants; they are always public
1745
1747
Item { visibility : self . vis . clean ( cx) , ..what_rustc_thinks }
1746
1748
}
1747
1749
}
@@ -2298,7 +2300,7 @@ impl Clean<Item> for doctree::Macro<'_> {
2298
2300
} ) ,
2299
2301
cx,
2300
2302
) ;
2301
- // need to override attrs explicitly in case this was inlined
2303
+ // rustc_metadata strips attributes on macros; use the attributes from the HIR instead
2302
2304
Item { attrs : self . attrs . clean ( cx) , ..what_rustc_thinks }
2303
2305
}
2304
2306
}
You can’t perform that action at this time.
0 commit comments