File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ use visit_ast;
4040
4141/// A stable identifier to the particular version of JSON output.
4242/// Increment this when the `Crate` and related structures change.
43- pub static SCHEMA_VERSION : & ' static str = "0.8.2 " ;
43+ pub static SCHEMA_VERSION : & ' static str = "0.8.3 " ;
4444
4545mod inline;
4646
@@ -449,6 +449,7 @@ pub struct TyParam {
449449 pub name : String ,
450450 pub did : ast:: DefId ,
451451 pub bounds : Vec < TyParamBound > ,
452+ pub default : Option < Type >
452453}
453454
454455impl Clean < TyParam > for ast:: TyParam {
@@ -457,6 +458,7 @@ impl Clean<TyParam> for ast::TyParam {
457458 name : self . ident . clean ( ) ,
458459 did : ast:: DefId { krate : ast:: LOCAL_CRATE , node : self . id } ,
459460 bounds : self . bounds . clean ( ) . move_iter ( ) . collect ( ) ,
461+ default : self . default . clean ( )
460462 }
461463 }
462464}
@@ -470,6 +472,7 @@ impl Clean<TyParam> for ty::TypeParameterDef {
470472 name : self . ident . clean ( ) ,
471473 did : self . def_id ,
472474 bounds : self . bounds . clean ( ) ,
475+ default : self . default . clean ( )
473476 }
474477 }
475478}
Original file line number Diff line number Diff line change @@ -82,6 +82,11 @@ impl fmt::Show for clean::Generics {
8282 try!( write ! ( f, "{}" , * bound) ) ;
8383 }
8484 }
85+
86+ match tp. default {
87+ Some ( ref ty) => { try!( write ! ( f, " = {}" , ty) ) ; } ,
88+ None => { }
89+ } ;
8590 }
8691 }
8792 try!( f. write ( ">" . as_bytes ( ) ) ) ;
You can’t perform that action at this time.
0 commit comments