pitrou commented on code in PR #45852:
URL: https://github.com/apache/arrow/pull/45852#discussion_r2001729997
##########
cpp/src/arrow/util/bit_util_test.cc:
##########
@@ -1589,16 +1589,19 @@ TEST(BitUtilTests, TestCopyBitmap) {
std::vector<int64_t> lengths = {kBufferSize * 8 - 4, kBufferSize * 8};
std::vector<int64_t> offsets = {0, 12, 16, 32, 37, 63, 64, 128};
- for (int64_t num_bits : lengths) {
- for (int64_t offset : offsets) {
- const int64_t copy_length = num_bits - offset;
+ for (bool maintan_offset : {true, false}) {
+ for (int64_t num_bits : lengths) {
+ for (int64_t offset : offsets) {
+ const int64_t copy_length = num_bits - offset;
Review Comment:
It would be better to test with different offsets, for example:
```suggestion
for (int64_t num_bits : lengths) {
for (int64_t offset : offsets) {
for (int64_t dest_offset : {0, offset - 1, offset + 1}) {
const int64_t copy_length = num_bits - offset;
```
--
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]