Skip to content

Commit 5151dd9

Browse files
committed
Fix checkerframework issues
1 parent 2db5249 commit 5151dd9

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

key.util/src/main/java/org/key_project/util/collection/ImmutableArray.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ public Iterator<S> iterator() {
162162
return new ArrayIterator<>(this);
163163
}
164164

165-
private static class ArrayIterator<T> implements Iterator<T> {
165+
private static class ArrayIterator<T extends @Nullable Object> implements Iterator<T> {
166166

167167
private int i = 0;
168168
private final ImmutableArray<T> coll;

key.util/src/main/java/org/key_project/util/collection/Immutables.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ private Immutables() {
163163
*
164164
* @return the view onto the iterable as an immutable list
165165
*/
166-
public static <T> ImmutableList<T> createListFrom(Iterable<? extends T> iterable) {
166+
public static <T extends @Nullable Object> ImmutableList<T> createListFrom(Iterable<? extends T> iterable) {
167167
ImmutableList<T> result = ImmutableSLList.nil();
168168
for (T t : iterable) {
169169
result = result.prepend(t);

settings.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ include 'key.format'
1919

2020
// ENABLE NULLNESS here or on the CLI
2121
// This flag is activated to enable the checker framework.
22-
// System.setProperty("ENABLE_NULLNESS", "true")
22+
System.setProperty("ENABLE_NULLNESS", "true")

0 commit comments

Comments
 (0)