bkietz commented on a change in pull request #8703:
URL: https://github.com/apache/arrow/pull/8703#discussion_r528213657



##########
File path: cpp/src/arrow/array/diff.h
##########
@@ -59,6 +57,27 @@ ARROW_EXPORT
 Result<std::shared_ptr<StructArray>> Diff(const Array& base, const Array& 
target,
                                           MemoryPool* pool = 
default_memory_pool());
 
+/// \brief Compare two array ranges, returning an edit script which expresses 
the
+/// difference between them
+///
+/// Same as Diff(), but only the ranges defined by the given offsets and 
lengths
+/// are compared.
+///
+/// \param[in] base baseline for comparison
+/// \param[in] target an array of identical type to base whose elements differ 
from base's
+/// \param[in] base_offset the start offset of the range to consider inside 
`base`
+/// \param[in] base_length the length of the range to consider inside `base`
+/// \param[in] target_offset the start offset of the range to consider inside 
`target`
+/// \param[in] target_length the length of the range to consider inside 
`target`
+/// \param[in] pool memory to store the result will be allocated from this 
memory pool
+/// \return an edit script array which can be applied to base to produce target
+ARROW_EXPORT
+Result<std::shared_ptr<StructArray>> DiffRanges(const Array& base, const 
Array& target,

Review comment:
       Right; if you wanted to minimize this patch some then this could be 
removed




----------------------------------------------------------------
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:
[email protected]


Reply via email to