Skip to content

Conversation

Alex-PLACET
Copy link
Collaborator

No description provided.

@Alex-PLACET Alex-PLACET self-assigned this Aug 19, 2025
pre-commit-ci bot and others added 5 commits August 19, 2025 10:46
Copy link

codecov bot commented Aug 19, 2025

Codecov Report

❌ Patch coverage is 90.62500% with 18 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.07%. Comparing base (7e1a023) to head (b2c6f37).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
...nclude/sparrow/variable_size_binary_view_array.hpp 90.57% 18 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #526      +/-   ##
==========================================
- Coverage   88.11%   88.07%   -0.04%     
==========================================
  Files         100      100              
  Lines        7470     7639     +169     
==========================================
+ Hits         6582     6728     +146     
- Misses        888      911      +23     
Flag Coverage Δ
unittests 88.07% <90.62%> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds mutation support to the variable size binary view array implementation, enabling resize, insert, and erase operations. The implementation provides comprehensive mutating functionality while managing the complex storage layout of binary view arrays with their inline storage optimization for strings ≤12 bytes.

Key changes:

  • Adds assignment, resize, insert, and erase methods to the binary view array
  • Implements comprehensive test coverage for all mutation operations
  • Fixes assertion logic in the base class to allow empty range operations

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
include/sparrow/variable_size_binary_view_array.hpp Adds mutating methods (assign, resize_values, insert_value, insert_values, erase_values) with complex buffer management logic
include/sparrow/layout/mutable_array_base.hpp Fixes assertion to allow empty range erases (first == last)
test/test_variable_size_binary_view_array.cpp Comprehensive test suite covering all mutation scenarios including edge cases

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

else
{
// Growing: insert copies of value at the end
insert_value(value_cend(), value, new_length - current_size);
Copy link
Preview

Copilot AI Aug 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The variable 'value' is being passed to insert_value, but the parameter is named 'value' in the function signature. This creates a name collision and could lead to confusion. The function parameter should be used here instead.

Copilot uses AI. Check for mistakes.

proxy.update_buffers();

// Return iterator to element after last erased, or end if we erased to the end
return erase_index < new_size ? sparrow::next(value_begin(), erase_index) : value_end();
Copy link
Preview

Copilot AI Aug 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The variable name 'erase_index_bis' used earlier (line 1450) suggests there might be naming conflicts. Consider using more descriptive variable names to avoid confusion between the two erase_index variables.

Copilot uses AI. Check for mistakes.

@Alex-PLACET Alex-PLACET marked this pull request as draft August 25, 2025 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant