From bc1d8e7f6b3cf47f06693c0955fe560089792b3d Mon Sep 17 00:00:00 2001 From: Alexandre Montplaisir Date: Fri, 30 Oct 2015 16:48:15 -0400 Subject: [PATCH] Augment annotation to Map.entrySet() We already annotated Map.entrySet() to return a @NonNull Set> But actually, the returned Set should not contain any null elements, since then entry objects will always exist, even if the key and/or value is null. So we could augment the annotation to: @NonNull Set<@NonNull Map.Entry> K and V in this case need to remain unannotated, their type should match the Map's declaration. Change-Id: Id436fd3cfc4f679198070e5efdbb9d2d3ce478ae Signed-off-by: Alexandre Montplaisir Reviewed-on: https://git.eclipse.org/r/59422 Reviewed-by: Hudson CI Reviewed-by: Marc-Andre Laperle Tested-by: Marc-Andre Laperle --- .../annotations/java/util/Map.eea | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/org.eclipse.tracecompass.common.core/annotations/java/util/Map.eea b/common/org.eclipse.tracecompass.common.core/annotations/java/util/Map.eea index 44f25b374d..f538bf972f 100644 --- a/common/org.eclipse.tracecompass.common.core/annotations/java/util/Map.eea +++ b/common/org.eclipse.tracecompass.common.core/annotations/java/util/Map.eea @@ -1,7 +1,7 @@ class java/util/Map entrySet ()Ljava/util/Set;>; - ()L1java/util/Set;>; + ()L1java/util/Set;>; get (Ljava/lang/Object;)TV; (Ljava/lang/Object;)T0V; -- 2.34.1