]> git.lizzy.rs Git - rust.git/commitdiff
Add a test for removing nested parens
authorSeiichi Uchida <seuchida@gmail.com>
Thu, 8 Mar 2018 11:25:06 +0000 (20:25 +0900)
committerSeiichi Uchida <seuchida@gmail.com>
Thu, 8 Mar 2018 11:25:06 +0000 (20:25 +0900)
tests/source/paren.rs [new file with mode: 0644]
tests/target/paren.rs [new file with mode: 0644]

diff --git a/tests/source/paren.rs b/tests/source/paren.rs
new file mode 100644 (file)
index 0000000..09ac6b1
--- /dev/null
@@ -0,0 +1,8 @@
+// Remove nested parens.
+
+fn main() {
+    let x = (((1)));
+    let y = (/* comment */((2)));
+    let z = (((3)/* comment */));
+    let a = (((4/* comment */)));
+}
diff --git a/tests/target/paren.rs b/tests/target/paren.rs
new file mode 100644 (file)
index 0000000..3856991
--- /dev/null
@@ -0,0 +1,8 @@
+// Remove nested parens.
+
+fn main() {
+    let x = (1);
+    let y = (/* comment */(2));
+    let z = ((3)/* comment */);
+    let a = (4/* comment */);
+}