Skip to content

Commit b43a08d

Browse files
committed
feat:Fix parameter comparison and return optimization in ExecutableElementComparator
1 parent 945020d commit b43a08d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

microsphere-annotation-processor/src/main/java/io/microsphere/annotation/processor/util/ExecutableElementComparator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public int compare(ExecutableElement e1, ExecutableElement e2) {
5454
if (value == 0) { // Step 2
5555

5656
List<? extends VariableElement> ps1 = e1.getParameters();
57-
List<? extends VariableElement> ps2 = e1.getParameters();
57+
List<? extends VariableElement> ps2 = e2.getParameters();
5858

5959
value = ps1.size() - ps2.size();
6060

@@ -67,6 +67,6 @@ public int compare(ExecutableElement e1, ExecutableElement e2) {
6767
}
6868
}
6969
}
70-
return Integer.compare(value, 0);
70+
return value;
7171
}
7272
}

0 commit comments

Comments
 (0)