Enable PMD rule PrimitiveWrapperInstantiation and fix violations

This commit is contained in:
Manuel Fuhr 2023-05-09 22:13:57 +02:00
parent 7a6d3bd9d9
commit 28f205c1ad
12 changed files with 20 additions and 21 deletions

View file

@ -28,7 +28,7 @@ public class CompactSetTest {
for (int i = 0; i < setsize; i++) {
long k = setsize < 10 ? i : rand.nextInt(20000);
Long KK = new Long(k);
Long KK = k;
if (!hset.contains(KK)) {
hset.add(KK);
@ -43,7 +43,7 @@ public class CompactSetTest {
cset_fast = new FrozenLongSet(cset_fast);
}
long k = setsize < 10 ? i : rand.nextInt(20000);
Long KK = new Long(k);
Long KK = k;
boolean contained = hset.contains(KK);
Assert.assertEquals("contains missmatch (slow)", contained, cset_slow.contains(k));