icexelloss commented on code in PR #35513: URL: https://github.com/apache/arrow/pull/35513#discussion_r1190143574
########## cpp/src/arrow/engine/substrait/function_test.cc: ########## @@ -626,10 +629,22 @@ std::shared_ptr<acero::ExecPlan> PlanFromAggregateCase( ConversionOptions conversion_options; conversion_options.named_table_provider = std::move(table_provider); + struct TestConsumerFactory { + std::shared_ptr<acero::SinkNodeConsumer> operator()() { return consumer; } + std::shared_ptr<acero::SinkNodeConsumer> consumer; + }; EXPECT_OK_AND_ASSIGN( - std::shared_ptr<acero::ExecPlan> plan, - DeserializePlan(*substrait, std::move(consumer), default_extension_id_registry(), - /*ext_set_out=*/nullptr, conversion_options)); + auto declarations, + DeserializePlans(*substrait, TestConsumerFactory{std::move(consumer)}, Review Comment: Does something like this work? (using lambda expression) ``` DeserializePlans(*buf, [consumer] { return consumer; }, ...) ``` -- 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: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org