zeroshade commented on code in PR #36489:
URL: https://github.com/apache/arrow/pull/36489#discussion_r1261369405


##########
cpp/src/arrow/c/bridge.cc:
##########
@@ -663,6 +672,112 @@ Status ExportRecordBatch(const RecordBatch& batch, struct 
ArrowArray* out,
   return Status::OK();
 }
 
+//////////////////////////////////////////////////////////////////////////
+// C device arrays
+
+Status ValidateDeviceInfo(const ArrayData& data, DeviceType* device_type,
+                          int64_t* device_id) {

Review Comment:
   That brings me back to my original implementation vs this tail recursion 
version that @felipecrv suggested haha. 
   
   This is the internal recursive call, below it is the intended function to 
call which does return `Result<std::pair<DeviceType, int64_t>>`



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