@@ -1725,7 +1725,10 @@ fn print_item(cx: &Context, item: &clean::Item, buf: &mut Buffer, cache: &Cache)
1725
1725
"Module "
1726
1726
}
1727
1727
}
1728
- clean:: FunctionItem ( ..) | clean:: ForeignFunctionItem ( ..) => "Function " ,
1728
+ clean:: FunctionItem ( ..)
1729
+ | clean:: ForeignFunctionItem ( ..)
1730
+ | clean:: TyMethodItem ( ..)
1731
+ | clean:: MethodItem ( ..) => "Function " ,
1729
1732
clean:: TraitItem ( ..) => "Trait " ,
1730
1733
clean:: StructItem ( ..) => "Struct " ,
1731
1734
clean:: UnionItem ( ..) => "Union " ,
@@ -1746,7 +1749,7 @@ fn print_item(cx: &Context, item: &clean::Item, buf: &mut Buffer, cache: &Cache)
1746
1749
clean:: TraitAliasItem ( ..) => "Trait Alias " ,
1747
1750
_ => {
1748
1751
// We don't generate pages for any other type.
1749
- unreachable ! ( ) ;
1752
+ unreachable ! ( "unknown kind {:?}" , item . kind ) ;
1750
1753
}
1751
1754
} ;
1752
1755
buf. write_str ( name) ;
@@ -1768,9 +1771,10 @@ fn print_item(cx: &Context, item: &clean::Item, buf: &mut Buffer, cache: &Cache)
1768
1771
1769
1772
match item. kind {
1770
1773
clean:: ModuleItem ( ref m) => item_module ( buf, cx, item, & m. items ) ,
1771
- clean:: FunctionItem ( ref f) | clean:: ForeignFunctionItem ( ref f) => {
1772
- item_function ( buf, cx, item, f)
1773
- }
1774
+ clean:: FunctionItem ( ref f)
1775
+ | clean:: ForeignFunctionItem ( ref f)
1776
+ | clean:: TyMethodItem ( ref f)
1777
+ | clean:: MethodItem ( ref f, _) => item_function ( buf, cx, item, f) ,
1774
1778
clean:: TraitItem ( ref t) => item_trait ( buf, cx, item, t, cache) ,
1775
1779
clean:: StructItem ( ref s) => item_struct ( buf, cx, item, s, cache) ,
1776
1780
clean:: UnionItem ( ref s) => item_union ( buf, cx, item, s, cache) ,
@@ -1787,7 +1791,7 @@ fn print_item(cx: &Context, item: &clean::Item, buf: &mut Buffer, cache: &Cache)
1787
1791
clean:: TraitAliasItem ( ref ta) => item_trait_alias ( buf, cx, item, ta, cache) ,
1788
1792
_ => {
1789
1793
// We don't generate pages for any other type.
1790
- unreachable ! ( ) ;
1794
+ unreachable ! ( "unknown kind {:?}" , item . kind ) ;
1791
1795
}
1792
1796
}
1793
1797
}
0 commit comments