]> git.lizzy.rs Git - rust.git/blobdiff - tests/target/struct_lits_visual.rs
Merge pull request #681 from rust-lang-nursery/comment-style
[rust.git] / tests / target / struct_lits_visual.rs
index bf73db5a8157e32a2963a90ae9e1552b956419ff..d5978c3debbe94dc9cbcd5b77b4431cbb4b4d698 100644 (file)
@@ -1,4 +1,5 @@
-// rustfmt-struct_lit_style: VisualIndent
+// rustfmt-wrap_comments: true
+// rustfmt-struct_lit_style: Visual
 
 // Struct literal expressions.
 
@@ -13,10 +14,10 @@ fn main() {
           b: bar(),
           ..something };
 
-    Fooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo { a: foo(),
-                                                                               b: bar(), };
+    Fooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo { a: f(), b: b() };
 
-    Foooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo { // Comment
+    Foooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo { // Commen
+                                                                                        // t
                                                                                         a: foo(), /* C
                                                                                                    * o
                                                                                                    * m
@@ -24,7 +25,8 @@ fn main() {
                                                                                                    * e
                                                                                                    * n
                                                                                                    * t */
-                                                                                        // Comment
+                                                                                        // Commen
+                                                                                        // t
                                                                                         b: bar(), /* C
                                                                                                    * o
                                                                                                    * m
@@ -33,13 +35,16 @@ fn main() {
                                                                                                    * n
                                                                                                    * t */ };
 
-    Foo { a: Bar, b: foo() };
+    Foo { a: Bar, b: f() };
 
     Quux { x: if cond {
                bar();
            },
            y: baz(), };
 
+    Baz { x: yxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,
+          z: zzzzz, /* test */ };
+
     A { // Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit
         // amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante
         // hendrerit. Donec et mollis dolor.