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

Soften generic constraint of Buffer #1152

Merged
merged 1 commit into from
Jul 12, 2022

Conversation

sundy-li
Copy link
Collaborator

@sundy-li sundy-li commented Jul 11, 2022

make constraint in buffer freer

@codecov
Copy link

codecov bot commented Jul 11, 2022

Codecov Report

Merging #1152 (096a562) into main (1cd7453) will decrease coverage by 0.00%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #1152      +/-   ##
==========================================
- Coverage   83.67%   83.66%   -0.01%     
==========================================
  Files         365      365              
  Lines       35869    35869              
==========================================
- Hits        30012    30011       -1     
- Misses       5857     5858       +1     
Impacted Files Coverage Δ
src/buffer/immutable.rs 89.33% <ø> (ø)
src/bitmap/utils/slice_iterator.rs 97.56% <0.00%> (-1.22%) ⬇️
src/io/ipc/read/common.rs 94.92% <0.00%> (-0.40%) ⬇️
src/io/ipc/read/reader.rs 96.32% <0.00%> (+0.33%) ⬆️

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 1cd7453...096a562. Read the comment docs.

@jorgecarleitao
Copy link
Owner

This is a nice idea! I think we can make this even stronger -

pub struct Buffer<T> {...}

impl<T: std::fmt::Debug> std::fmt::Debug for Buffer<T> {...}

i.e. no constraint.

Side: could you describe what is the goal? I am genuinely curious

@sundy-li
Copy link
Collaborator Author

Side: could you describe what is the goal? I am genuinely curious

I want to use Buffer<u256> and Buffer<u512> in databend.

@sundy-li sundy-li changed the title chore(buffer): make constraint in buffer shorter chore(buffer): make constraint in buffer more free Jul 12, 2022
@sundy-li sundy-li changed the title chore(buffer): make constraint in buffer more free chore(buffer): make constraint in buffer freer Jul 12, 2022
@jorgecarleitao jorgecarleitao changed the title chore(buffer): make constraint in buffer freer Soften generic constraint of Buffer Jul 12, 2022
@jorgecarleitao jorgecarleitao merged commit 6de9edf into jorgecarleitao:main Jul 12, 2022
@jorgecarleitao jorgecarleitao added the enhancement An improvement to an existing feature label Jul 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement An improvement to an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants