@@ -63,17 +63,14 @@ public boolean canConvert(final Class<?> src, final Class<?> dest) {
6363 @ Override
6464 public <T > T convert (final Object src , final Class <T > dest ) {
6565 // NB: Regardless of whether the destination type is an array or
66- // collection,
67- // we still want to cast directly if doing so is possible. But note that
68- // in
69- // general, this check does not detect cases of incompatible generic
70- // parameter types. If this limitation becomes a problem in the future
71- // we
72- // can extend the logic here to provide additional signatures of canCast
73- // which operate on Types in general rather than only Classes. However,
74- // the
75- // logic could become complex very quickly in various subclassing cases,
76- // generic parameters resolved vs. propagated, etc.
66+ // collection, we still want to cast directly if doing so is possible.
67+ // But note that in general, this check does not detect cases of
68+ // incompatible generic parameter types. If this limitation becomes a
69+ // problem in the future we can extend the logic here to provide
70+ // additional signatures of canCast which operate on Types in general
71+ // rather than only Classes. However, the logic could become complex
72+ // very quickly in various subclassing cases, generic parameters
73+ // resolved vs. propagated, etc.
7774 final Class <?> c = GenericUtils .getClass (dest );
7875 return (T ) ConversionUtils .cast (src , c );
7976 }
0 commit comments