You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by le...@apache.org on 2019/07/04 02:23:11 UTC
[incubator-datasketches-memory] branch master updated: Fix
unsupported warnings
This is an automated email from the ASF dual-hosted git repository.
leerho pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-memory.git
The following commit(s) were added to refs/heads/master by this push:
new fc3db16 Fix unsupported warnings
fc3db16 is described below
commit fc3db1627871697d4b52f47b54492e599c079c92
Author: Lee Rhodes <le...@users.noreply.github.com>
AuthorDate: Wed Jul 3 19:23:01 2019 -0700
Fix unsupported warnings
---
.../org/apache/datasketches/memory/WritableMemoryTest.java | 4 ++--
src/test/java/org/apache/datasketches/memory/XxHash64Test.java | 10 +++++-----
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/test/java/org/apache/datasketches/memory/WritableMemoryTest.java b/src/test/java/org/apache/datasketches/memory/WritableMemoryTest.java
index fad9ae3..28be3f4 100644
--- a/src/test/java/org/apache/datasketches/memory/WritableMemoryTest.java
+++ b/src/test/java/org/apache/datasketches/memory/WritableMemoryTest.java
@@ -83,7 +83,7 @@ public class WritableMemoryTest {
public void checkEquals() {
int len = 7;
WritableMemory wmem1 = WritableMemory.allocate(len);
- @SuppressWarnings({"EqualsWithItself", "SelfEquals"})
+ //@SuppressWarnings({"EqualsWithItself", "SelfEquals"})
//SelfEquals for Plexus, EqualsWithItself for IntelliJ
boolean eq1 = wmem1.equals(wmem1);
assertTrue(eq1);
@@ -126,7 +126,7 @@ public class WritableMemoryTest {
int len = 23;
WritableMemory wmem1 = WritableMemory.allocate(len);
assertFalse(wmem1.equals(null));
- @SuppressWarnings({"EqualsWithItself", "SelfEquals"})
+ //@SuppressWarnings({"EqualsWithItself", "SelfEquals"})
//SelfEquals for Plexus, EqualsWithItself for IntelliJ
boolean eq1 = wmem1.equals(wmem1);
assertTrue(eq1);
diff --git a/src/test/java/org/apache/datasketches/memory/XxHash64Test.java b/src/test/java/org/apache/datasketches/memory/XxHash64Test.java
index 99670c4..ece3ee6 100644
--- a/src/test/java/org/apache/datasketches/memory/XxHash64Test.java
+++ b/src/test/java/org/apache/datasketches/memory/XxHash64Test.java
@@ -83,7 +83,7 @@ public class XxHash64Test {
* OpenHFT/Zero-Allocation-Hashing</a> to test hash compatibility with that implementation.
*/
@Test
- @SuppressWarnings("ConstantOverflow")
+ //@SuppressWarnings("ConstantOverflow")
public void collisionTest() {
WritableMemory wmem = WritableMemory.allocate(128);
wmem.putLong(0, 1);
@@ -91,13 +91,13 @@ public class XxHash64Test {
wmem.putLong(32, 2);
long h1 = wmem.xxHash64(0, wmem.getCapacity(), 0);
- wmem.putLong(0, 1 + 0xBA79078168D4BAFL);
- wmem.putLong(32, 2 + 0x9C90005B80000000L);
+ wmem.putLong(0, 1L + 0xBA79078168D4BAFL);
+ wmem.putLong(32, 2L + 0x9C90005B80000000L);
long h2 = wmem.xxHash64(0, wmem.getCapacity(), 0);
assertEquals(h1, h2);
- wmem.putLong(0, 1 + (0xBA79078168D4BAFL * 2));
- wmem.putLong(32, 2 + (0x9C90005B80000000L * 2));
+ wmem.putLong(0, 1L + (0xBA79078168D4BAFL * 2));
+ wmem.putLong(32, 2L + (0x9C90005B80000000L * 2));
long h3 = wmem.xxHash64(0, wmem.getCapacity(), 0);
assertEquals(h2, h3);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org