@@ -842,7 +842,7 @@ private static boolean satisfiesRawTypes(final Type arg, final Type param) {
842842 final List <Class <?>> destClasses = Types .raws (param );
843843 for (final Class <?> destClass : destClasses ) {
844844 final Optional <Class <?>> first = srcClasses .stream ().filter (
845- srcClass -> destClass . isAssignableFrom (srcClass )).findFirst ();
845+ srcClass -> Types . isAssignable (srcClass , destClass )).findFirst ();
846846 if (!first .isPresent ()) {
847847 // TODO can we remove this?
848848// throw new IllegalArgumentException("Argument #" + i + //
@@ -977,12 +977,12 @@ private static boolean satisfiesWildcardType(final Type arg,
977977 for (final Type upperBound : upperBounds ) {
978978 // check that the argument can satisfy the parameter
979979 final Class <?> upperType = Types .raw (upperBound );
980- if (! upperType . isAssignableFrom (argType )) return false ;
980+ if (! Types . isAssignable (argType , upperType )) return false ;
981981 }
982982 for (final Type lowerBound : lowerBounds ) {
983983 final Class <?> lowerType = Types .raw (lowerBound );
984984 // check that the argument can satisfy the parameter
985- if (! argType . isAssignableFrom (lowerType )) return false ;
985+ if (! Types . isAssignable (lowerType , argType )) return false ;
986986 }
987987
988988 return true ;
@@ -1018,8 +1018,7 @@ else if (paramComponent instanceof TypeVariable) {
10181018 // something other than a ParameterizedType or a TypeVariable.
10191019 final Class <?> argClass = Types .raw (argComponent );
10201020 final Class <?> paramClass = Types .raw (paramComponent );
1021- if (!paramClass .isAssignableFrom (argClass )) return false ;
1022- return true ;
1021+ return Types .isAssignable (argClass , paramClass );
10231022 }
10241023
10251024 /**
0 commit comments