Skip to content

Commit 60664db

Browse files
gselzerwiedenm
authored andcommitted
WIP: pass TypeAssigns along to more places
TODO: make sure this is a good thing
1 parent c1c219b commit 60664db

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/org/scijava/ops/matcher/MatchingUtils.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ private static boolean checkGenericAssignability(Type[] srcTypes, Type[] destTyp
336336
// assignability
337337
Class<?> matchingRawType = Types.raw(dest);
338338
Type inferredSrcType = Types.parameterize(matchingRawType, mappedSrcTypes);
339-
if (!Types.isAssignable(inferredSrcType, dest)) {
339+
if (!Types.isAssignable(inferredSrcType, dest, typeVarAssigns)) {
340340
if (!safeAssignability || !isSafeAssignable(destTypes, typeVarAssigns, src, dest))
341341
return false;
342342
}
@@ -477,7 +477,7 @@ private static void inferTypeVariables(Type[] types, Type[] inferFrom, Map<TypeV
477477
if (!(inferFrom[i] instanceof ParameterizedType)) {
478478
Type[] fromType = { types[i] };
479479
fromType = Types.mapVarToTypes(fromType, typeAssigns);
480-
if (!Types.isAssignable(inferFrom[i], fromType[0])) {
480+
if (!Types.isAssignable(inferFrom[i], fromType[0], typeAssigns)) {
481481
throw new TypeInferenceException();
482482
}
483483
} else {

0 commit comments

Comments
 (0)