waynexia commented on PR #6336: URL: https://github.com/apache/arrow-rs/pull/6336#issuecomment-2359937096
>I have a concern that after turning the `MutableBuffer` into a `Buffer` it would not be freed with the correct allocator. Adding a generic parameter to `Buffer` would affect a lot more apis, maybe it could use the existing `Deallocation::Custom` strategy somehow. Good catch :+1: I've limited those `freeze()` APIs to `Global` alloc in 6b28b10. Now it should not be possible to construct a `Buffer` with memory from other allocators. I'll add this functionalities back when implementing allocator param for `Buffer` in the follow up PR. >A unit test with a custom allocator, to be run with miri, would be very nice. New test `mutable_buffer_with_custom_allocator` in 02d73ad. There is a script `.github/workflows/miri.sh` to run it -- 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]
