Workaround for Eclipse
- Current Eclipse compiler fails to infer appropriate generic type. Workaround the issue by explicitly specifying the type. Might be related to: https://bugs.eclipse.org/bugs/show_bug.cgi?id=467561 Change-Id: I7f41fd1a33f165fa8a57120a6f9a42cf587f94cc
Showing
1 changed file
with
1 additions
and
1 deletions
... | @@ -91,7 +91,7 @@ public class DefaultDistributedQueue<E> implements DistributedQueue<E> { | ... | @@ -91,7 +91,7 @@ public class DefaultDistributedQueue<E> implements DistributedQueue<E> { |
91 | .whenComplete((r, e) -> timer.stop(e)) | 91 | .whenComplete((r, e) -> timer.stop(e)) |
92 | .thenCompose(v -> { | 92 | .thenCompose(v -> { |
93 | if (v != null) { | 93 | if (v != null) { |
94 | - return CompletableFuture.completedFuture(serializer.decode(v)); | 94 | + return CompletableFuture.<E>completedFuture(serializer.decode(v)); |
95 | } | 95 | } |
96 | CompletableFuture<E> newPendingFuture = new CompletableFuture<>(); | 96 | CompletableFuture<E> newPendingFuture = new CompletableFuture<>(); |
97 | pendingFutures.add(newPendingFuture); | 97 | pendingFutures.add(newPendingFuture); | ... | ... |
-
Please register or login to post a comment