rustdoc: Support unboxed fn sugar in bounds

This commit is contained in:
Tom Jakubowski
2014-10-05 08:09:41 -07:00
parent 2f955c73d6
commit 7be20574e0
3 changed files with 21 additions and 9 deletions

View File

@@ -143,8 +143,8 @@ impl fmt::Show for clean::TyParamBound {
clean::RegionBound(ref lt) => {
write!(f, "{}", *lt)
}
clean::UnboxedFnBound(..) => {
write!(f, "Fn(???)") // FIXME
clean::UnboxedFnBound(ref ty) => {
write!(f, "{}{}", ty.path, ty.decl)
}
clean::UnknownBound => {
write!(f, "'static")
@@ -408,7 +408,7 @@ impl fmt::Show for clean::Type {
for bound in decl.bounds.iter() {
match *bound {
clean::RegionBound(..) |
clean::UnboxedFnBound |
clean::UnboxedFnBound(..) |
clean::UnknownBound => {}
clean::TraitBound(ref t) => {
if ret.len() == 0 {