Add checkerframework nullness annotations to accepted list for AnnotationTest (#5409)

Also use checkerframework annotations instead of jetbrains ones for Inventory#getContents as jetbrains ones do not allow properly annotating the nullability of an array and it's contents.
This commit is contained in:
Jason Penilla
2021-03-24 03:02:32 -07:00
parent 4a1f5cb85e
commit a12e69774f
2 changed files with 36 additions and 1 deletions

View File

@@ -15,7 +15,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
- @NotNull
- public ItemStack[] getContents();
-
+ public @Nullable ItemStack @NotNull [] getContents(); // Paper - make array elements nullable instead array
+ public @org.checkerframework.checker.nullness.qual.Nullable ItemStack @org.checkerframework.checker.nullness.qual.NonNull [] getContents(); // Paper - make array elements nullable instead array
+
/**
* Completely replaces the inventory's contents. Removes all existing