@@ -499,7 +499,7 @@ pub trait PrintState<'a>: std::ops::Deref<Target = pp::Printer> + std::ops::Dere
499499 ast:: MetaItemKind :: List ( ref items) => {
500500 self . print_path ( & item. path , false , 0 ) ;
501501 self . popen ( ) ;
502- self . commasep ( Consistent , & items[ .. ] , |s, i| s. print_meta_list_item ( i) ) ;
502+ self . commasep ( Consistent , & items, |s, i| s. print_meta_list_item ( i) ) ;
503503 self . pclose ( ) ;
504504 }
505505 }
@@ -997,7 +997,7 @@ impl<'a> State<'a> {
997997 }
998998 ast:: TyKind :: Tup ( ref elts) => {
999999 self . popen ( ) ;
1000- self . commasep ( Inconsistent , & elts[ .. ] , |s, ty| s. print_type ( ty) ) ;
1000+ self . commasep ( Inconsistent , & elts, |s, ty| s. print_type ( ty) ) ;
10011001 if elts. len ( ) == 1 {
10021002 self . s . word ( "," ) ;
10031003 }
@@ -1017,10 +1017,10 @@ impl<'a> State<'a> {
10171017 ast:: TyKind :: Path ( Some ( ref qself) , ref path) => self . print_qpath ( path, qself, false ) ,
10181018 ast:: TyKind :: TraitObject ( ref bounds, syntax) => {
10191019 let prefix = if syntax == ast:: TraitObjectSyntax :: Dyn { "dyn" } else { "" } ;
1020- self . print_type_bounds ( prefix, & bounds[ .. ] ) ;
1020+ self . print_type_bounds ( prefix, & bounds) ;
10211021 }
10221022 ast:: TyKind :: ImplTrait ( _, ref bounds) => {
1023- self . print_type_bounds ( "impl" , & bounds[ .. ] ) ;
1023+ self . print_type_bounds ( "impl" , & bounds) ;
10241024 }
10251025 ast:: TyKind :: Array ( ref ty, ref length) => {
10261026 self . s . word ( "[" ) ;
@@ -1339,7 +1339,7 @@ impl<'a> State<'a> {
13391339 real_bounds. push ( b. clone ( ) ) ;
13401340 }
13411341 }
1342- self . print_type_bounds ( ":" , & real_bounds[ .. ] ) ;
1342+ self . print_type_bounds ( ":" , & real_bounds) ;
13431343 self . print_where_clause ( & generics. where_clause ) ;
13441344 self . s . word ( " " ) ;
13451345 self . bopen ( ) ;
@@ -1368,7 +1368,7 @@ impl<'a> State<'a> {
13681368 }
13691369 }
13701370 self . nbsp ( ) ;
1371- self . print_type_bounds ( "=" , & real_bounds[ .. ] ) ;
1371+ self . print_type_bounds ( "=" , & real_bounds) ;
13721372 self . print_where_clause ( & generics. where_clause ) ;
13731373 self . s . word ( ";" ) ;
13741374 }
@@ -1960,10 +1960,10 @@ impl<'a> State<'a> {
19601960 self . print_expr_tup ( exprs) ;
19611961 }
19621962 ast:: ExprKind :: Call ( ref func, ref args) => {
1963- self . print_expr_call ( func, & args[ .. ] ) ;
1963+ self . print_expr_call ( func, & args) ;
19641964 }
19651965 ast:: ExprKind :: MethodCall ( ref segment, ref args, _) => {
1966- self . print_expr_method_call ( segment, & args[ .. ] ) ;
1966+ self . print_expr_method_call ( segment, & args) ;
19671967 }
19681968 ast:: ExprKind :: Binary ( op, ref lhs, ref rhs) => {
19691969 self . print_expr_binary ( op, lhs, rhs) ;
@@ -2443,11 +2443,11 @@ impl<'a> State<'a> {
24432443 self . print_path ( path, true , 0 ) ;
24442444 }
24452445 self . popen ( ) ;
2446- self . commasep ( Inconsistent , & elts[ .. ] , |s, p| s. print_pat ( p) ) ;
2446+ self . commasep ( Inconsistent , & elts, |s, p| s. print_pat ( p) ) ;
24472447 self . pclose ( ) ;
24482448 }
24492449 PatKind :: Or ( ref pats) => {
2450- self . strsep ( "|" , true , Inconsistent , & pats[ .. ] , |s, p| s. print_pat ( p) ) ;
2450+ self . strsep ( "|" , true , Inconsistent , & pats, |s, p| s. print_pat ( p) ) ;
24512451 }
24522452 PatKind :: Path ( None , ref path) => {
24532453 self . print_path ( path, true , 0 ) ;
@@ -2465,7 +2465,7 @@ impl<'a> State<'a> {
24652465 self . word_space ( "{" ) ;
24662466 self . commasep_cmnt (
24672467 Consistent ,
2468- & fields[ .. ] ,
2468+ & fields,
24692469 |s, f| {
24702470 s. cbox ( INDENT_UNIT ) ;
24712471 if !f. is_shorthand {
@@ -2488,7 +2488,7 @@ impl<'a> State<'a> {
24882488 }
24892489 PatKind :: Tuple ( ref elts) => {
24902490 self . popen ( ) ;
2491- self . commasep ( Inconsistent , & elts[ .. ] , |s, p| s. print_pat ( p) ) ;
2491+ self . commasep ( Inconsistent , & elts, |s, p| s. print_pat ( p) ) ;
24922492 if elts. len ( ) == 1 {
24932493 self . s . word ( "," ) ;
24942494 }
@@ -2530,7 +2530,7 @@ impl<'a> State<'a> {
25302530 }
25312531 PatKind :: Slice ( ref elts) => {
25322532 self . s . word ( "[" ) ;
2533- self . commasep ( Inconsistent , & elts[ .. ] , |s, p| s. print_pat ( p) ) ;
2533+ self . commasep ( Inconsistent , & elts, |s, p| s. print_pat ( p) ) ;
25342534 self . s . word ( "]" ) ;
25352535 }
25362536 PatKind :: Rest => self . s . word ( ".." ) ,
@@ -2839,7 +2839,7 @@ impl<'a> State<'a> {
28392839 self . print_path ( & tree. prefix , false , 0 ) ;
28402840 self . s . word ( "::{" ) ;
28412841 }
2842- self . commasep ( Inconsistent , & items[ .. ] , |this, & ( ref tree, _) | {
2842+ self . commasep ( Inconsistent , & items, |this, & ( ref tree, _) | {
28432843 this. print_use_tree ( tree)
28442844 } ) ;
28452845 self . s . word ( "}" ) ;
0 commit comments