adriangb commented on code in PR #25970:
URL: https://github.com/apache/datafusion/pull/25970#discussion_r4299224353


##########
datafusion/functions-nested/src/concat.rs:
##########
@@ -419,11 +476,8 @@ fn append_prepend_return_type(
 
 /// Concatenates the list arrays in `args` row-wise.
 ///
-/// `field` is the list field the output must carry. `array_concat` passes 
`None`
-/// because its `return_type` derives a fresh field from the unified element
-/// types, which is what deriving the field from the aligned inputs reproduces.
-/// `array_append` / `array_prepend` promise their input's field verbatim and 
so
-/// must pass it in explicitly.
+/// `field` is the list field the output must carry when it differs from the
+/// aligned inputs' first field.

Review Comment:
   Nit: `array_concat` now always passes `Some(field)` (the planned type), so 
this sentence is a bit vague. Maybe say who passes what:
   
   ```suggestion
   /// `field` is the list field the output must carry. `array_concat` passes 
the
   /// inner field of its planned return type, and `array_append` / 
`array_prepend`
   /// pass their input's field. `None` derives the field from the aligned 
inputs.
   ```



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