]> git.lizzy.rs Git - rust.git/blobdiff - tests/target/expr-block.rs
Cargo fmt and update tests
[rust.git] / tests / target / expr-block.rs
index 194798ff472718c6ccdfbdbcfc2a8c066d0c99ea..329890e8b12f6350912a64bdfc45b7c1627b423e 100644 (file)
@@ -80,11 +80,7 @@ fn arrays() {
         0,
     ];
 
-    let y = [
-        /* comment */ 1,
-        2, /* post comment */
-        3,
-    ];
+    let y = [/* comment */ 1, 2 /* post comment */, 3];
 
     let xy = [
         strukt {
@@ -116,8 +112,8 @@ fn function_calls() {
         context.codemap,
         args.iter(),
         ")",
-        |item| item.span.lo,
-        |item| item.span.hi,
+        |item| item.span.lo(),
+        |item| item.span.hi(),
         |item| {
             item.rewrite(
                 context,
@@ -127,16 +123,16 @@ fn function_calls() {
                 },
             )
         },
-        span.lo,
-        span.hi,
+        span.lo(),
+        span.hi(),
     );
 
     itemize_list(
         context.codemap,
         args.iter(),
         ")",
-        |item| item.span.lo,
-        |item| item.span.hi,
+        |item| item.span.lo(),
+        |item| item.span.hi(),
         |item| {
             item.rewrite(
                 context,
@@ -146,8 +142,8 @@ fn function_calls() {
                 },
             )
         },
-        span.lo,
-        span.hi,
+        span.lo(),
+        span.hi(),
     )
 }
 
@@ -201,8 +197,8 @@ fn issue_1450() {
 }
 
 fn foo() {
-    if real_total <= limit && !pre_line_comments &&
-        !items.into_iter().any(|item| item.as_ref().is_multiline())
+    if real_total <= limit && !pre_line_comments
+        && !items.into_iter().any(|item| item.as_ref().is_multiline())
     {
         DefinitiveListTactic::Horizontal
     }
@@ -311,9 +307,7 @@ fn combine_block() {
     };
 
     match x {
-        y => func(
-            xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,
-        ),
+        y => func(xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx),
         _ => func(
             x,
             yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy,