kkraus14 commented on code in PR #37365:
URL: https://github.com/apache/arrow/pull/37365#discussion_r1310462828


##########
cpp/src/arrow/device.h:
##########
@@ -109,19 +109,50 @@ class ARROW_EXPORT Device : public 
std::enable_shared_from_this<Device>,
   /// should be trivially constructible from it's device-specific counterparts.
   class ARROW_EXPORT Stream {
    public:
-    virtual const void* get_raw() const { return NULLPTR; }
+    using release_fn_t = void (*)(void*);

Review Comment:
   Should we consider making this `std::function` instead of a raw function 
pointer here? Using the former would allow for passing lambda captures at the 
cost of some overhead. Lambda captures would be useful for something like if 
someone has a smart pointer managing the lifetime of a stream.



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