FrankChen021 commented on code in PR #20367:
URL: https://github.com/apache/druid/pull/20367#discussion_r4079230855


##########
sql/src/main/java/org/apache/druid/sql/calcite/planner/DruidRexExecutor.java:
##########
@@ -246,4 +256,45 @@ private static String getInputValueOrExpression(final 
RexNode constExp)
     }
     return constExp.toString();
   }
+
+  ///
+  /// Reduces literal string and integer arrays without formatting, parsing, 
or evaluating a Druid expression.
+  ///
+  /// Reuses the original array call when every literal's type matches the 
array component type, ignoring nullability.
+  /// These literals already have the required types and values, so rebuilding 
them would only add allocations.
+  /// Nullability differences do not require conversion: a non-null literal 
may belong to an array with nullable elements,
+  /// and reusing the call preserves both null values and the original array 
type.
+  ///
+  /// Returns null for mismatched element types, unsupported types, or 
non-literal operands (including CAST calls).
+  /// These retain the existing Druid expression evaluation path, including 
any required type normalization.
+  ///

Review Comment:
   This is markdown format Java doc from JDK 23



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to