Commit 47d5e0c 1 parent 6084705 commit 47d5e0c Copy full SHA for 47d5e0c
File tree 1 file changed +1
-6
lines changed
jetty-core/jetty-util/src/main/java/org/eclipse/jetty/util
1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,6 @@ public class TypeUtil
65
65
public static final int CR = '\r' ;
66
66
public static final int LF = '\n' ;
67
67
private static final Pattern TRAILING_DIGITS = Pattern .compile ("^\\ D*(\\ d+)$" );
68
- private static final ListIterator <?> EMPTY_LIST_ITERATOR = Collections .EMPTY_LIST .listIterator ();
69
68
70
69
private static final HashMap <String , Class <?>> name2Class = new HashMap <>();
71
70
@@ -189,11 +188,7 @@ public static <T> ListIterator<T> listIteratorAtEnd(List<T> list)
189
188
{
190
189
int size = list .size ();
191
190
if (size == 0 )
192
- {
193
- @ SuppressWarnings ("unchecked" )
194
- ListIterator <T > emptyListIterator = (ListIterator <T >)EMPTY_LIST_ITERATOR ;
195
- return emptyListIterator ;
196
- }
191
+ return Collections .emptyListIterator ();
197
192
return list .listIterator (size );
198
193
}
199
194
catch (IndexOutOfBoundsException e )
You can’t perform that action at this time.
0 commit comments