bug fix in clone

git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@918 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 25 years ago
parent 7d6364d507
commit 7aa5200869
  1. 6
      jode/jode/util/SimpleSet.java

@ -63,11 +63,7 @@ public class SimpleSet
public Object clone() {
try {
SimpleSet other = (SimpleSet) super.clone();
if (count > 0) {
other.elementObjects = new Object[count];
System.arraycopy(elementObjects, 0,
other.elementObjects, 0, count);
}
other.elementObjects = (Object[]) elementObjects.clone();
return other;
} catch (CloneNotSupportedException ex) {
throw new jode.AssertError("Clone?");

Loading…
Cancel
Save