commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1543971 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
Date Wed, 20 Nov 2013 22:16:05 GMT
Author: tn
Date: Wed Nov 20 22:16:05 2013
New Revision: 1543971

URL: http://svn.apache.org/r1543971
Log:
Fix for java 1.5 compilation.

Modified:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java?rev=1543971&r1=1543970&r2=1543971&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
Wed Nov 20 22:16:05 2013
@@ -50,8 +50,8 @@ public class ComparatorUtils {
      *
      * @see ComparableComparator#comparableComparator()
      */
-    @SuppressWarnings("rawtypes")
-    public static final Comparator NATURAL_COMPARATOR = ComparableComparator.comparableComparator();
+    @SuppressWarnings({ "rawtypes", "unchecked" }) // explicit type needed for Java 1.5 compilation
+    public static final Comparator NATURAL_COMPARATOR = ComparableComparator.<Comparable>comparableComparator();
 
     /**
      * Gets a comparator that uses the natural order of the objects.



Mime
View raw message