kou commented on code in PR #14417:
URL: https://github.com/apache/arrow/pull/14417#discussion_r995841709
##########
ruby/red-arrow/lib/arrow/raw-table-converter.rb:
##########
@@ -35,7 +35,11 @@ def convert
fields = []
@values = []
@raw_table.each do |name, array|
- array = ArrayBuilder.build(array) if array.is_a?(::Array)
+ if array.respond_to?(:to_arrow_array)
+ array = array.to_arrow_array
+ elsif array.is_a?(::Array)
Review Comment:
It's a good idea.
I've added support for `#to_ary`.
--
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]