From 5bf7699dd432904cf52a012c72d8653771cef97f Mon Sep 17 00:00:00 2001 From: "ray.j.greenwell" Date: Wed, 13 Jan 2010 17:49:25 +0000 Subject: [PATCH] Missed a spot. Oh baby, look at the @SuppressWarnings and cast removal. It's all itchy, flakey, and pale under the cast! git-svn-id: https://samskivert.googlecode.com/svn/trunk@2695 6335cc39-0255-0410-8fd6-9bcaacd3b74c --- src/java/com/samskivert/util/HashIntMap.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/java/com/samskivert/util/HashIntMap.java b/src/java/com/samskivert/util/HashIntMap.java index d56cf458..1aa583ba 100644 --- a/src/java/com/samskivert/util/HashIntMap.java +++ b/src/java/com/samskivert/util/HashIntMap.java @@ -463,8 +463,7 @@ public class HashIntMap extends AbstractMap Record[] buckets = result._buckets = result._buckets.clone(); for (int ii = buckets.length - 1; ii >= 0; ii--) { if (buckets[ii] != null) { - @SuppressWarnings("unchecked") - Record entry = (Record) buckets[ii].clone(); + Record entry = buckets[ii].clone(); buckets[ii] = entry; } } @@ -585,15 +584,14 @@ public class HashIntMap extends AbstractMap return key + "=" + StringUtil.toString(value); } - @Override public Object clone () + @Override public Record clone () { try { @SuppressWarnings("unchecked") Record result = (Record) super.clone(); // value is not cloned if (result.next != null) { - @SuppressWarnings("unchecked") - Record next = (Record) result.next.clone(); + Record next = result.next.clone(); result.next = next; } return result;