mirror of
https://github.com/moparisthebest/fernflower
synced 2025-02-17 23:40:21 -05:00
java-decompiler: post-import cleanup (test sources reformatted)
This commit is contained in:
parent
e629738a46
commit
c0c83126a6
Binary file not shown.
@ -26,10 +26,10 @@ public class TestClassLambda {
|
||||
public void testLambda1() {
|
||||
int var1 = (int)Math.random();
|
||||
Runnable var2 = () -> {
|
||||
System.out.println("hello" + var1);
|
||||
System.out.println("hello1" + var1);
|
||||
};
|
||||
Runnable var3 = () -> {
|
||||
System.out.println("hello1" + var1);
|
||||
System.out.println("hello2" + var1);
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -15,10 +15,7 @@
|
||||
*/
|
||||
package pkg;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.OptionalInt;
|
||||
import java.util.*;
|
||||
import java.util.function.IntBinaryOperator;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
@ -27,20 +24,19 @@ public class TestClassLambda {
|
||||
public int field = 0;
|
||||
|
||||
public void testLambda() {
|
||||
|
||||
List<Integer> list = Arrays.asList(1, 2, 3, 4, 5, 6, 7);
|
||||
int b = (int)Math.random();
|
||||
|
||||
list.forEach(n -> {int a = 2 * n; System.out.println(a + b + field);});
|
||||
list.forEach(n -> {
|
||||
int a = 2 * n;
|
||||
System.out.println(a + b + field);
|
||||
});
|
||||
}
|
||||
|
||||
public void testLambda1() {
|
||||
|
||||
int a = (int)Math.random();
|
||||
|
||||
Runnable r = () -> { System.out.println("hello" + a); };
|
||||
|
||||
Runnable r1 = () -> { System.out.println("hello1" + a); };
|
||||
Runnable r2 = () -> { System.out.println("hello2" + a); };
|
||||
}
|
||||
|
||||
public void testLambda2() {
|
||||
@ -78,5 +74,4 @@ public class TestClassLambda {
|
||||
public static int localMax(int first, int second) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -22,7 +22,6 @@ public class TestClassLoop {
|
||||
while (true) {
|
||||
System.out.println();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static void testFinally() {
|
||||
@ -34,11 +33,11 @@ public class TestClassLoop {
|
||||
if (!a) {
|
||||
return;
|
||||
}
|
||||
} finally {
|
||||
}
|
||||
finally {
|
||||
System.out.println("1");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static void testFinallyContinue() {
|
||||
@ -48,7 +47,8 @@ public class TestClassLoop {
|
||||
for (; ; ) {
|
||||
try {
|
||||
System.out.println("1");
|
||||
} finally {
|
||||
}
|
||||
finally {
|
||||
if (a) {
|
||||
System.out.println("3");
|
||||
continue;
|
||||
@ -57,7 +57,5 @@ public class TestClassLoop {
|
||||
|
||||
System.out.println("4");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -27,5 +27,4 @@ public class TestClassSwitch {
|
||||
System.out.println(5);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -27,7 +27,8 @@ public class TestClassTypes {
|
||||
|
||||
if (time % 2 > 0) {
|
||||
var7 = 1;
|
||||
} else if(time % 3 > 0) {
|
||||
}
|
||||
else if (time % 3 > 0) {
|
||||
var7 = 2;
|
||||
}
|
||||
|
||||
@ -65,5 +66,4 @@ public class TestClassTypes {
|
||||
|
||||
System.out.println(a.size());
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -27,12 +27,12 @@ public class TestClassVar {
|
||||
|
||||
try {
|
||||
System.out.println();
|
||||
} finally {
|
||||
}
|
||||
finally {
|
||||
if (field_boolean) {
|
||||
System.out.println();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -48,12 +48,12 @@ public class TestClassVar {
|
||||
|
||||
int b = a;
|
||||
|
||||
for(; a < 10 && a == 0; a++) {}
|
||||
for (; a < 10 && a == 0; a++) {
|
||||
}
|
||||
|
||||
if (b != a) {
|
||||
System.out.println();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user