[GitHub] [arrow] nealrichardson commented on a change in pull request #7318: ARROW-8917: [C++] Formalize "metafunction" concept. Add Take and Filter metafunctions, port R and Python bindings

2020-06-06 Thread GitBox


nealrichardson commented on a change in pull request #7318:
URL: https://github.com/apache/arrow/pull/7318#discussion_r436304103



##
File path: r/R/chunked-array.R
##
@@ -75,23 +75,15 @@ ChunkedArray <- R6Class("ChunkedArray", inherit = 
ArrowObject,
   if (is.integer(i)) {
 i <- Array$create(i)
   }
-  # Invalid: Kernel does not support chunked array arguments
-  # so use the old method for both cases
-  if (inherits(i, "ChunkedArray")) {
-return(shared_ptr(ChunkedArray, ChunkedArray__TakeChunked(self, i)))
-  }
-  assert_is(i, "Array")
-  return(shared_ptr(ChunkedArray, ChunkedArray__Take(self, i)))
+  # Invalid: Tried executing function with non-value type: ChunkedArray

Review comment:
   Done in 
https://github.com/apache/arrow/pull/7308/commits/247a1048e85871214e0456f3ee347a9b3e5388da





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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [arrow] nealrichardson commented on a change in pull request #7318: ARROW-8917: [C++] Formalize "metafunction" concept. Add Take and Filter metafunctions, port R and Python bindings

2020-06-02 Thread GitBox


nealrichardson commented on a change in pull request #7318:
URL: https://github.com/apache/arrow/pull/7318#discussion_r434285021



##
File path: r/R/table.R
##
@@ -146,21 +146,15 @@ Table <- R6Class("Table", inherit = ArrowObject,
   if (is.integer(i)) {
 i <- Array$create(i)
   }
-  if (inherits(i, "ChunkedArray")) {
-return(shared_ptr(Table, Table__TakeChunked(self, i)))
-  }
-  assert_is(i, "Array")
-  shared_ptr(Table, Table__Take(self, i))
+  # Invalid: Tried executing function with non-value type: Table

Review comment:
   Another comment to remove?





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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [arrow] nealrichardson commented on a change in pull request #7318: ARROW-8917: [C++] Formalize "metafunction" concept. Add Take and Filter metafunctions, port R and Python bindings

2020-06-02 Thread GitBox


nealrichardson commented on a change in pull request #7318:
URL: https://github.com/apache/arrow/pull/7318#discussion_r434284600



##
File path: r/R/record-batch.R
##
@@ -121,14 +121,13 @@ RecordBatch <- R6Class("RecordBatch", inherit = 
ArrowObject,
   assert_is(i, "Array")
   # Invalid: Tried executing function with non-value type: RecordBatch
   # so use old methods
-  shared_ptr(RecordBatch, RecordBatch__Take(self, i))
+  shared_ptr(RecordBatch, call_function("take", self, i))

Review comment:
   Likewise should remove comment above, which is no longer valid.





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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [arrow] nealrichardson commented on a change in pull request #7318: ARROW-8917: [C++] Formalize "metafunction" concept. Add Take and Filter metafunctions, port R and Python bindings

2020-06-02 Thread GitBox


nealrichardson commented on a change in pull request #7318:
URL: https://github.com/apache/arrow/pull/7318#discussion_r434284526



##
File path: r/R/chunked-array.R
##
@@ -75,23 +75,15 @@ ChunkedArray <- R6Class("ChunkedArray", inherit = 
ArrowObject,
   if (is.integer(i)) {
 i <- Array$create(i)
   }
-  # Invalid: Kernel does not support chunked array arguments
-  # so use the old method for both cases
-  if (inherits(i, "ChunkedArray")) {
-return(shared_ptr(ChunkedArray, ChunkedArray__TakeChunked(self, i)))
-  }
-  assert_is(i, "Array")
-  return(shared_ptr(ChunkedArray, ChunkedArray__Take(self, i)))
+  # Invalid: Tried executing function with non-value type: ChunkedArray

Review comment:
   Is this comment (still) valid? Looks like this is calling 
`call_function` now





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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org