File tree Expand file tree Collapse file tree 1 file changed +6
-10
lines changed Expand file tree Collapse file tree 1 file changed +6
-10
lines changed Original file line number Diff line number Diff line change @@ -2639,27 +2639,23 @@ impl<'a> State<'a> {
26392639 self . s . word ( "<" ) ;
26402640
26412641 self . commasep ( Inconsistent , & generic_params, |s, param| {
2642+ s. print_outer_attributes_inline ( & param. attrs ) ;
2643+
26422644 match param. kind {
26432645 ast:: GenericParamKind :: Lifetime => {
2644- s. print_outer_attributes_inline ( & param. attrs ) ;
26452646 let lt = ast:: Lifetime { id : param. id , ident : param. ident } ;
26462647 s. print_lifetime_bounds ( lt, & param. bounds )
26472648 }
26482649 ast:: GenericParamKind :: Type { ref default } => {
2649- s. print_outer_attributes_inline ( & param. attrs ) ;
26502650 s. print_ident ( param. ident ) ;
26512651 s. print_type_bounds ( ":" , & param. bounds ) ;
2652- match default {
2653- Some ( ref default) => {
2654- s. s . space ( ) ;
2655- s. word_space ( "=" ) ;
2656- s. print_type ( default)
2657- }
2658- _ => { }
2652+ if let Some ( ref default) = default {
2653+ s. s . space ( ) ;
2654+ s. word_space ( "=" ) ;
2655+ s. print_type ( default)
26592656 }
26602657 }
26612658 ast:: GenericParamKind :: Const { ref ty } => {
2662- s. print_outer_attributes_inline ( & param. attrs ) ;
26632659 s. word_space ( "const" ) ;
26642660 s. print_ident ( param. ident ) ;
26652661 s. s . space ( ) ;
You can’t perform that action at this time.
0 commit comments