Esempio n. 1
0
 @Override
 public final boolean isSubtype(AnnotatedTypeMirror rhs, AnnotatedTypeMirror lhs) {
   if (lhs.getKind() == TypeKind.TYPEVAR && rhs.getKind() == TypeKind.TYPEVAR) {
     // TODO: Investigate whether there is a nicer and more proper way to
     // get assignments between two type variables working.
     if (lhs.getAnnotations().isEmpty()) {
       return true;
     }
   }
   // Otherwise Covariant would cause trouble.
   if (rhs.hasAnnotation(KeyForBottom.class)) {
     return true;
   }
   return super.isSubtype(rhs, lhs);
 }