fix annotation matching in duplicates finder

This commit is contained in:
Bas Leijdekkers
2016-11-21 17:09:15 +01:00
parent 9a8244764b
commit cbab61f15b
7 changed files with 177 additions and 20 deletions
@@ -0,0 +1,13 @@
class C {
{
@A int i = 0;
System.out.println(i);
}
void f() {
<selection>@B int j = 0;
System.out.println(j);</selection>
}
}
@interface A {}
@interface B {}
@@ -0,0 +1,17 @@
class C {
{
@A int i = 0;
System.out.println(i);
}
void f() {
newMethod();
}
private void newMethod() {
@B int j = 0;
System.out.println(j);
}
}
@interface A {}
@interface B {}
@@ -0,0 +1,19 @@
class C {
{
@A(value="asdf") int i = 0;
System.out.println(i);
}
void f() {
<selection>@A int j = 0;
System.out.println(j);</selection>
}
void g() {
@A("asdf") int k = 0;
System.out.println(k);
}
}
@interface A {
String value() default "asdf";
}
@@ -0,0 +1,21 @@
class C {
{
newMethod();
}
void f() {
newMethod();
}
private void newMethod() {
@A int j = 0;
System.out.println(j);
}
void g() {
newMethod();
}
}
@interface A {
String value() default "asdf";
}