Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

expose shrink_to_fit to mutable arrays #467

Merged
merged 3 commits into from
Oct 2, 2021

Conversation

ritchie46
Copy link
Collaborator

This PR proposes to expose shrink_to_fit on the mutable arrays. The MutableBuffer already implements this, but its impossible to call with mutable array API as the internal buffers are private.

The same could be done for MutableBitmap.

@ritchie46 ritchie46 changed the title expose shrink_to_fit to mutable arrays expose shrink_to_fit to mutable arrays Sep 29, 2021
@codecov
Copy link

codecov bot commented Sep 29, 2021

Codecov Report

Merging #467 (1533023) into main (a15044a) will decrease coverage by 0.17%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #467      +/-   ##
==========================================
- Coverage   80.33%   80.16%   -0.18%     
==========================================
  Files         374      374              
  Lines       22919    22969      +50     
==========================================
+ Hits        18413    18414       +1     
- Misses       4506     4555      +49     
Impacted Files Coverage Δ
src/array/binary/mutable.rs 61.11% <0.00%> (-2.24%) ⬇️
src/array/boolean/mutable.rs 82.68% <0.00%> (-2.87%) ⬇️
src/array/dictionary/mutable.rs 70.76% <0.00%> (-5.90%) ⬇️
src/array/fixed_size_binary/mutable.rs 67.03% <0.00%> (-4.74%) ⬇️
src/array/fixed_size_list/mutable.rs 48.52% <0.00%> (-4.70%) ⬇️
src/array/list/mutable.rs 66.33% <0.00%> (-4.94%) ⬇️
src/array/mod.rs 54.62% <ø> (ø)
src/array/primitive/mutable.rs 83.79% <0.00%> (-2.40%) ⬇️
src/array/utf8/mutable.rs 85.25% <0.00%> (-2.45%) ⬇️
src/io/avro/read/schema.rs 42.52% <0.00%> (+1.14%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a15044a...1533023. Read the comment docs.

@jorgecarleitao
Copy link
Owner

Yeap, makes a lot of sense.

@jorgecarleitao
Copy link
Owner

I can take care of the MutableBitmap and we can then rebase on top of that.

@jorgecarleitao
Copy link
Owner

Done in #468

@ritchie46
Copy link
Collaborator Author

I can take care of the MutableBitmap and we can then rebase on top of that.

Great, once #468 is in main, I will do the rebase and add the MutableBitmap shrinking as well.

@jorgecarleitao jorgecarleitao added the feature A new feature label Sep 30, 2021
@ritchie46
Copy link
Collaborator Author

Good to go!

Copy link
Owner

@jorgecarleitao jorgecarleitao left a comment

Choose a reason for hiding this comment

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

Looks great! Thanks a lot, @ritchie46 ! We are missing one buffer xD

src/array/binary/mutable.rs Show resolved Hide resolved
@jorgecarleitao jorgecarleitao merged commit b7e9913 into jorgecarleitao:main Oct 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature A new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants