Skip to content

Commit

Permalink
Update some comments
Browse files Browse the repository at this point in the history
  • Loading branch information
zanmato1984 committed Oct 13, 2024
1 parent 0811b2b commit 154ad95
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cpp/src/arrow/compute/kernels/vector_placement_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ void DoTestPermuteAAA(const std::shared_ptr<Array>& values,
}

/// The following helper functions are based on the invariant:
/// PermuteXXA([V, V], [I', I''], 2 * l) == Concat(E, E)
/// Permute([V, V], [I', I''], 2 * l) == Concat(E, E)
///
/// where
/// V = values
Expand Down Expand Up @@ -1008,6 +1008,9 @@ void DoTestIfElse(const Expression& cond, const Expression& if_true,
ASSERT_TRUE(result_by_expr.is_array());
ASSERT_OK_AND_ASSIGN(Datum result_by_permute,
ExecuteIfElseByPermute(cond, if_true, if_false, schema, input));
// Permute will output chunked array because we inputs values and indices as chunked
// arrays consisting of each branches. We don't care the shape of the output when
// comparing the results - only contents, so we concatenate the chunked array.
ASSERT_TRUE(result_by_permute.is_chunked_array());
ASSERT_OK_AND_ASSIGN(auto result_by_permute_concat,
Concatenate(result_by_permute.chunked_array()->chunks()));
Expand Down

0 comments on commit 154ad95

Please sign in to comment.