alamb commented on code in PR #6590:
URL: https://github.com/apache/arrow-rs/pull/6590#discussion_r1808986589


##########
arrow-buffer/src/buffer/immutable.rs:
##########
@@ -357,6 +357,12 @@ impl Buffer {
     pub fn ptr_eq(&self, other: &Self) -> bool {
         self.ptr == other.ptr && self.length == other.length
     }
+
+    /// Register this [`Buffer`] with the provided [`MemoryPool`]
+    #[cfg(feature = "pool")]
+    pub fn claim(&self, pool: &dyn crate::MemoryPool) {

Review Comment:
   I was thinking like if only some Arrays in a RecordBatch have a reservation 
but some didn't and then a system like the DataFusion memory pool added an 
entirely new reservation for all the arrays wiping out the old reservations
   
   In that case I would want the previous reservations to be unregistered
   
   Although maybe `Drop` would be good enough for that case 🤔 



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