Jiabao-Sun commented on code in PR #3430:
URL: https://github.com/apache/calcite/pull/3430#discussion_r1333319224


##########
core/src/main/java/org/apache/calcite/sql/type/ReturnTypes.java:
##########
@@ -645,6 +645,13 @@ public static SqlCall stripSeparator(SqlCall call) {
   public static final SqlReturnTypeInference TO_ARRAY =
       ARG0.andThen(SqlTypeTransforms.TO_ARRAY);
 
+  /**
+   * Same as {@link #TO_ARRAY} but returns with nullability if any of the
+   * operands is nullable.
+   */
+  public static final SqlReturnTypeInference ARRAY_NULLABLE =

Review Comment:
   Thanks @tanclary for the review.
   `ARRAY_NULLABLE`'s naming refers to `MULTISET` because they are all 
collection types.
   I am not sure if this is appropriate. 
   If you think it should be named `TO_ARRAY_NULLABLE `, I can correct it.
   
   ```java
     /**
      * Returns a MULTISET type.
      *
      * <p>For example, given <code>INTEGER</code>, returns
      * <code>INTEGER MULTISET</code>.
      */
     public static final SqlReturnTypeInference TO_MULTISET =
         ARG0.andThen(SqlTypeTransforms.TO_MULTISET);
   
     /**
      * Same as {@link #MULTISET} but returns with nullability if any of the
      * operands is nullable.
      */
     public static final SqlReturnTypeInference MULTISET_NULLABLE =
         MULTISET.andThen(SqlTypeTransforms.TO_NULLABLE);
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to