remove unused assignment: do not move the transformed statement up as it could change the semantic and is not evident (IDEA-123841)

This commit is contained in:
Anna Kozlova
2014-04-14 21:38:55 +02:00
parent 36771d7d8e
commit b708f2006e
3 changed files with 37 additions and 2 deletions
@@ -0,0 +1,15 @@
// "Remove redundant assignment" "true"
class A {
A a = null;
String m(String str) {
return str;
}
{
String ss = "";
System.out.println();
a.m(ss);
}
}
@@ -0,0 +1,15 @@
// "Remove redundant assignment" "true"
class A {
A a = null;
String m(String str) {
return str;
}
{
String ss = "";
System.out.println();
s<caret>s = a.m(ss);
}
}