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


##########
datafusion/common/src/scalar/mod.rs:
##########
@@ -5300,7 +5300,18 @@ impl ScalarValue {
     /// `LargeListView`, `Struct`, `Map`) are handled by recursing into their
     /// child / values arrays and reconstructing the parent with the compacted
     /// children.  All other types are returned unchanged.
-    fn compact_view_buffers(array: ArrayRef) -> ArrayRef {
+    ///
+    /// `gc` copies the bytes of each view separately. Views that share bytes,
+    /// such as the output of `take` with repeated indices, each get their own
+    /// copy, so the result can be larger than the input.
+    ///
+    /// # Public Only for Internal Use:
+    ///
+    /// This is not a public API and is for internal use only; see [API 
policy] for details.
+    ///
+    /// [API policy]: 
https://datafusion.apache.org/contributor-guide/api-health.html#internal-public-apis
+    #[doc(hidden)]
+    pub fn compact_view_buffers(array: ArrayRef) -> ArrayRef {

Review Comment:
   Is a method on `ScalarValue` really the best place to put this utility?



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