public static TensorType outputType(TensorType a, TensorType b) {
        try {
            return TypeResolver.join(a, b);
        }
        catch (IllegalArgumentException e) {
            throw new IllegalArgumentException("Can not join " + a + " and " + b, e);
        }
    }
Returns the type resulting from applying Join to the two given types
vespajlib/src/main/java/com/yahoo/tensor/functions/Join.java