Skip to content

Commit 0040f80

Browse files
committed
inferTypeVariables: avoid recursive bounds
Previously we were recursively checking bounds of type variables even if those bounds were themselves recursive. This would create duplicate mappings that worked incidentally because the values were the same (since recursive) but this behavior broke in the change to recurse to raw types instead (avoiding infinite recursion errors)
1 parent cd4cceb commit 0040f80

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scijava-types/src/main/java/org/scijava/types/inference/GenericAssignability.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -605,7 +605,7 @@ private static void inferTypeVariables(TypeVariable<?> type, Type inferFrom,
605605
throw new TypeInferenceException();
606606
}
607607
}
608-
else if (!Types.isRecurisveBound(type, bound)) {
608+
else if (!Types.isRecursiveBound(type, bound)) {
609609
// Else go into recursion as we encountered a new var.
610610
inferTypeVariables(bound, inferFrom, typeMappings);
611611
}

0 commit comments

Comments
 (0)