Skip to content

Commit

Permalink
run pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
zeroshade committed Nov 11, 2024
1 parent 6a0aa0a commit 53f564a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
7 changes: 4 additions & 3 deletions cpp/src/arrow/c/bridge.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2622,7 +2622,7 @@ class AsyncRecordBatchIterator {
private_data->fut_iterator_.MarkFinished(maybe_schema.status());
return EINVAL;
}

private_data->state_->schema_ = maybe_schema.MoveValueUnsafe();
private_data->fut_iterator_.MarkFinished(private_data->state_);
self->producer->request(self->producer,
Expand Down Expand Up @@ -2783,7 +2783,8 @@ struct AsyncProducer {
}

static int extract_data(struct ArrowAsyncTask* task, struct ArrowDeviceArray* out) {
std::unique_ptr<PrivateTaskData> private_data{reinterpret_cast<PrivateTaskData*>(task->private_data)};
std::unique_ptr<PrivateTaskData> private_data{
reinterpret_cast<PrivateTaskData*>(task->private_data)};
int ret = 0;
if (out != nullptr) {
auto status = ExportDeviceRecordBatch(*private_data->record_,
Expand All @@ -2793,7 +2794,7 @@ struct AsyncProducer {
private_data->producer_->error_ = status;
}
}

return ret;
}

Expand Down
11 changes: 6 additions & 5 deletions cpp/src/arrow/c/bridge.h
Original file line number Diff line number Diff line change
Expand Up @@ -412,8 +412,8 @@ Result<std::shared_ptr<ChunkedArray>> ImportDeviceChunkedArray(
///
/// @{

/// \brief EXPERIMENTAL: AsyncErrorDetail is a StatusDetail that contains an error code and message
/// from an asynchronous operation.
/// \brief EXPERIMENTAL: AsyncErrorDetail is a StatusDetail that contains an error code
/// and message from an asynchronous operation.
class AsyncErrorDetail : public StatusDetail {
public:
AsyncErrorDetail(int code, std::string message, std::string metadata)
Expand Down Expand Up @@ -444,8 +444,8 @@ namespace internal {
class Executor;
}

/// \brief EXPERIMENTAL: Create an AsyncRecordBatchReader and populate a corresponding handler to pass
/// to a producer
/// \brief EXPERIMENTAL: Create an AsyncRecordBatchReader and populate a corresponding
/// handler to pass to a producer
///
/// The ArrowAsyncDeviceStreamHandler struct is intended to have its callbacks populated
/// and then be passed to a producer to call the appropriate callbacks when data is ready.
Expand All @@ -464,7 +464,8 @@ Future<AsyncRecordBatchGenerator> CreateAsyncDeviceStreamHandler(
struct ArrowAsyncDeviceStreamHandler* handler, internal::Executor* executor,
uint64_t queue_size = 5, DeviceMemoryMapper mapper = DefaultDeviceMemoryMapper);

/// \brief EXPERIMENTAL: Export an AsyncGenerator of record batches using a provided handler
/// \brief EXPERIMENTAL: Export an AsyncGenerator of record batches using a provided
/// handler
///
/// This function calls the callbacks on the consumer-provided async handler as record
/// batches become available from the AsyncGenerator which is provided. It will first call
Expand Down

0 comments on commit 53f564a

Please sign in to comment.