code: public boolean isEqualityComparable(Type s, Type t, Warner warn) {
          if (t.isNumeric() && s.isNumeric())
              return true;
  
          boolean tPrimitive = t.isPrimitive();
          boolean sPrimitive = s.isPrimitive();
          if (!tPrimitive && !sPrimitive) {
              return isCastable(s, t, warn) || isCastable(t, s, warn);
          } else {
              return false;
          }
      }
docs: Can t and s be compared for equality?  Any primitive ==
  primitive or primitive == object comparisons here are an error.
  Unboxing and correct primitive == primitive comparisons are
  already dealt with in Attr.visitBinary.