-
Enhancement
-
Resolution: Unresolved
-
P5
-
None
-
In Review
int index = invalidComponents.indexOf(component);
if(index != -1) {
invalidComponents.remove(index);
}
No need to call List.indexOf(Object) before List.remove(int). Instead we can call List.remove(Object) directly. It's faster and cleaner.
invalidComponents is an ArrayList.
if(index != -1) {
invalidComponents.remove(index);
}
No need to call List.indexOf(Object) before List.remove(int). Instead we can call List.remove(Object) directly. It's faster and cleaner.
invalidComponents is an ArrayList.
- links to
-
Review(master) openjdk/jdk/24845