rtpsw commented on code in PR #13880:
URL: https://github.com/apache/arrow/pull/13880#discussion_r954278007


##########
cpp/src/arrow/compute/exec/asof_join_node.cc:
##########
@@ -602,52 +828,155 @@ class AsofJoinNode : public ExecNode {
 
  public:
   AsofJoinNode(ExecPlan* plan, NodeVector inputs, std::vector<std::string> 
input_labels,
-               const AsofJoinNodeOptions& join_options,
+               const vec_col_index_t& indices_of_on_key,
+               const std::vector<vec_col_index_t>& indices_of_by_key, OnType 
tolerance,
                std::shared_ptr<Schema> output_schema);
 
+  Status InternalInit(bool must_hash, bool nullable_by_key,
+                      std::vector<std::unique_ptr<KeyHasher>> key_hashers) {
+    key_hashers_.swap(key_hashers);

Review Comment:
   Before this line, the `key_hashers_` field is an empty vector. The swap 
effectively moves the elements in the `key_hashers` argument to the 
`key_hashers_` field, which ensures the elements are not destructed by the 
caller.



-- 
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]

Reply via email to