mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
Java inspection: Updated messages for "Move return to computation", added tests for 'switch' (IDEA-121153)
This commit is contained in:
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f() {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a[]) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
class T {
|
||||
int f(String a) {
|
||||
String s = a;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b, boolean c) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String a) {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a, int b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String[] a) {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = g();
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b, int d) {
|
||||
int n = d;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f() {
|
||||
String r = "";
|
||||
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
return 2;
|
||||
case 2:
|
||||
return 4;
|
||||
}
|
||||
return n;
|
||||
}
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
return 2;
|
||||
case 2:
|
||||
return 4;
|
||||
}
|
||||
return n;
|
||||
}
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
return 2;
|
||||
case 2:
|
||||
return 4;
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
return 2;
|
||||
case 2:
|
||||
return 4;
|
||||
default:
|
||||
return 0;
|
||||
case 0:
|
||||
}
|
||||
return n;
|
||||
}
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
return 2;
|
||||
default:
|
||||
return 0;
|
||||
case 2:
|
||||
return 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String p) {
|
||||
String r = null;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String p) {
|
||||
String r = null;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
long f() {
|
||||
long r;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = a;
|
||||
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
class T {
|
||||
int x;
|
||||
int y;
|
||||
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
if (a != 0) {
|
||||
n = a;
|
||||
n = 31 * x + n;
|
||||
n = 31 * y + n;
|
||||
}
|
||||
re<caret>turn n;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f() {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a[]) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'result'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'result'" "false"
|
||||
class T {
|
||||
int size;
|
||||
int width;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
class T {
|
||||
int f(String a) {
|
||||
String s = a;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b, boolean c) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f() {
|
||||
int n;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean a, boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 's'" "true"
|
||||
// "Move 'return' closer to computation of the value of 's'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String a) {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int[] a, int b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String[] a) {
|
||||
String r = "";
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = 0;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = g();
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b, int d) {
|
||||
int n = d;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f() {
|
||||
String r = "";
|
||||
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
n = 2;
|
||||
break;
|
||||
case 2:
|
||||
n = 4;
|
||||
break;
|
||||
}
|
||||
r<caret>eturn n;
|
||||
}
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
n = 2;
|
||||
break;
|
||||
case 2:
|
||||
n = 4;
|
||||
}
|
||||
ret<caret>urn n;
|
||||
}
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
n = 2;
|
||||
break;
|
||||
case 2:
|
||||
n = 4;
|
||||
break;
|
||||
default:
|
||||
n = 0;
|
||||
}
|
||||
ret<caret>urn n;
|
||||
}
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
n = 2;
|
||||
break;
|
||||
case 2:
|
||||
n = 4;
|
||||
break;
|
||||
default:
|
||||
n = 0;
|
||||
break;
|
||||
case 0:
|
||||
}
|
||||
re<caret>turn n;
|
||||
}
|
||||
}
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
switch (a) {
|
||||
case 1:
|
||||
n = 2;
|
||||
break;
|
||||
default:
|
||||
n = 0;
|
||||
break;
|
||||
case 2:
|
||||
n = 4;
|
||||
}
|
||||
ret<caret>urn n;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "false"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "false"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
import java.io.*;
|
||||
|
||||
class T {
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(boolean b) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String p) {
|
||||
String r = null;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'r'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'r'" "true"
|
||||
class T {
|
||||
String f(String p) {
|
||||
String r = null;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Move 'return' to computation of the value of 'n'" "true"
|
||||
// "Move 'return' closer to computation of the value of 'n'" "true"
|
||||
class T {
|
||||
int f(int a) {
|
||||
int n = -1;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user