1414pub use self :: Type :: * ;
1515pub use self :: Mutability :: * ;
1616pub use self :: ItemEnum :: * ;
17- pub use self :: GenericBound :: * ;
1817pub use self :: SelfTy :: * ;
1918pub use self :: FunctionRetTy :: * ;
2019pub use self :: Visibility :: { Public , Inherited } ;
@@ -1470,7 +1469,7 @@ impl GenericBound {
14701469 let path = external_path ( cx, & cx. tcx . item_name ( did) . as_str ( ) ,
14711470 Some ( did) , false , vec ! [ ] , empty) ;
14721471 inline:: record_extern_fqn ( cx, did, TypeKind :: Trait ) ;
1473- TraitBound ( PolyTrait {
1472+ GenericBound :: TraitBound ( PolyTrait {
14741473 trait_ : ResolvedPath {
14751474 path,
14761475 typarams : None ,
@@ -1510,8 +1509,10 @@ impl GenericBound {
15101509impl Clean < GenericBound > for hir:: GenericBound {
15111510 fn clean ( & self , cx : & DocContext ) -> GenericBound {
15121511 match * self {
1513- hir:: GenericBound :: Outlives ( lt) => Outlives ( lt. clean ( cx) ) ,
1514- hir:: GenericBound :: Trait ( ref t, modifier) => TraitBound ( t. clean ( cx) , modifier) ,
1512+ hir:: GenericBound :: Outlives ( lt) => GenericBound :: Outlives ( lt. clean ( cx) ) ,
1513+ hir:: GenericBound :: Trait ( ref t, modifier) => {
1514+ GenericBound :: TraitBound ( t. clean ( cx) , modifier)
1515+ }
15151516 }
15161517 }
15171518}
@@ -1599,7 +1600,7 @@ impl<'a, 'tcx> Clean<GenericBound> for (&'a ty::TraitRef<'tcx>, Vec<TypeBinding>
15991600 }
16001601 }
16011602
1602- TraitBound (
1603+ GenericBound :: TraitBound (
16031604 PolyTrait {
16041605 trait_ : ResolvedPath {
16051606 path,
@@ -1623,9 +1624,8 @@ impl<'tcx> Clean<GenericBound> for ty::TraitRef<'tcx> {
16231624impl < ' tcx > Clean < Option < Vec < GenericBound > > > for Substs < ' tcx > {
16241625 fn clean ( & self , cx : & DocContext ) -> Option < Vec < GenericBound > > {
16251626 let mut v = Vec :: new ( ) ;
1626- v. extend ( self . regions ( ) . filter_map ( |r| r. clean ( cx) )
1627- . map ( GenericBound :: Outlives ) ) ;
1628- v. extend ( self . types ( ) . map ( |t| TraitBound ( PolyTrait {
1627+ v. extend ( self . regions ( ) . filter_map ( |r| r. clean ( cx) ) . map ( GenericBound :: Outlives ) ) ;
1628+ v. extend ( self . types ( ) . map ( |t| GenericBound :: TraitBound ( PolyTrait {
16291629 trait_ : t. clean ( cx) ,
16301630 generic_params : Vec :: new ( ) ,
16311631 } , hir:: TraitBoundModifier :: None ) ) ) ;
@@ -2978,10 +2978,11 @@ impl Clean<Type> for hir::Ty {
29782978 match bounds[ 0 ] . clean ( cx) . trait_ {
29792979 ResolvedPath { path, typarams : None , did, is_generic } => {
29802980 let mut bounds: Vec < self :: GenericBound > = bounds[ 1 ..] . iter ( ) . map ( |bound| {
2981- TraitBound ( bound. clean ( cx) , hir:: TraitBoundModifier :: None )
2981+ self :: GenericBound :: TraitBound ( bound. clean ( cx) ,
2982+ hir:: TraitBoundModifier :: None )
29822983 } ) . collect ( ) ;
29832984 if !lifetime. is_elided ( ) {
2984- bounds. push ( self :: Outlives ( lifetime. clean ( cx) ) ) ;
2985+ bounds. push ( self :: GenericBound :: Outlives ( lifetime. clean ( cx) ) ) ;
29852986 }
29862987 ResolvedPath { path, typarams : Some ( bounds) , did, is_generic, }
29872988 }
@@ -3086,7 +3087,7 @@ impl<'tcx> Clean<Type> for Ty<'tcx> {
30863087 let path = external_path ( cx, & cx. tcx . item_name ( did) . as_str ( ) ,
30873088 Some ( did) , false , vec ! [ ] , empty) ;
30883089 inline:: record_extern_fqn ( cx, did, TypeKind :: Trait ) ;
3089- let bound = TraitBound ( PolyTrait {
3090+ let bound = GenericBound :: TraitBound ( PolyTrait {
30903091 trait_ : ResolvedPath {
30913092 path,
30923093 typarams : None ,
0 commit comments