summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarayan Kamath <narayan@google.com>2014-06-24 13:55:41 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-06-24 13:55:41 +0000
commit81f6bab5bc9eb0236b30413d7ef3147c745f5dcf (patch)
tree7ae23187f5369f70b99b227930a92a09374e2640
parent8e580fa5705019decefac99035704ac56cba5e7c (diff)
parentcd80a8301b9f5b262d30e982e85820d4dc9685d4 (diff)
downloadlibcore-81f6bab5bc9eb0236b30413d7ef3147c745f5dcf.zip
libcore-81f6bab5bc9eb0236b30413d7ef3147c745f5dcf.tar.gz
libcore-81f6bab5bc9eb0236b30413d7ef3147c745f5dcf.tar.bz2
am cd80a830: am baff7d7f: Merge "libcore: Clean up Enum.compareTo(E)"
* commit 'cd80a8301b9f5b262d30e982e85820d4dc9685d4': libcore: Clean up Enum.compareTo(E)
-rw-r--r--libart/src/main/java/java/lang/Enum.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/libart/src/main/java/java/lang/Enum.java b/libart/src/main/java/java/lang/Enum.java
index e9545a1..ac5fc9a 100644
--- a/libart/src/main/java/java/lang/Enum.java
+++ b/libart/src/main/java/java/lang/Enum.java
@@ -149,7 +149,7 @@ public abstract class Enum<E extends Enum<E>> implements Serializable, Comparabl
* @see java.lang.Comparable
*/
public final int compareTo(E o) {
- return ordinal - o.ordinal();
+ return ordinal - ((Enum<?>) o).ordinal;
}
/**