Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define starflate::{copy,copy_n} #109

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

oliverlee
Copy link
Collaborator

@oliverlee oliverlee commented Oct 21, 2023

starflate::{copy,copy_n} are variants of the standard library copy
and copy_n algorithms but modified for use in DEFLATE decoding. Both
of these algorithms specifically handle overlap of the source and
destination ranges.

starflate::copy_n takes an input iterator, distance, and output
iterator,

starflate::copy takes a source range and a destination range,
returning the unwritten subrange of the destination range.

Change-Id: I756a8416a82f4a2007c7f2461de04353aac667d6

@oliverlee oliverlee requested a review from garymm October 21, 2023 05:38
@oliverlee
Copy link
Collaborator Author

Not sure if this is the right place for this header since I don't imagine copy_n to be part of the public interface of starflate or decompress.

@oliverlee oliverlee force-pushed the I756a8416a82f4a2007c7f2461de04353aac667d6 branch from 7f78888 to 5f4cbee Compare October 21, 2023 05:41
@codecov
Copy link

codecov bot commented Oct 21, 2023

Codecov Report

Merging #109 (c2cd62a) into master (87d0405) will decrease coverage by 1.27%.
The diff coverage is 70.83%.

@@            Coverage Diff             @@
##           master     #109      +/-   ##
==========================================
- Coverage   58.98%   57.72%   -1.27%     
==========================================
  Files          12       13       +1     
  Lines         885      965      +80     
==========================================
+ Hits          522      557      +35     
- Misses        363      408      +45     
Files Coverage Δ
src/copy.hpp 70.83% <70.83%> (ø)

... and 1 file with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@oliverlee oliverlee force-pushed the I756a8416a82f4a2007c7f2461de04353aac667d6 branch 3 times, most recently from 5730ed5 to bc35ef4 Compare October 21, 2023 08:01
@oliverlee oliverlee changed the title Define starflate::copy_n Define starflate::{copy,copy_n} Oct 21, 2023
`starflate::{copy,copy_n}` are variants of the standard library `copy`
and `copy_n` algorithms but modified for use in DEFLATE decoding. Both
of these algorithms specifically handle overlap of the source and
destination ranges.

`starflate::copy_n` takes an input iterator, distance, and output
iterator,

`starflate::copy` takes a source range and a destination range,
returning the unwritten subrange of the destination range.

Change-Id: I756a8416a82f4a2007c7f2461de04353aac667d6
@oliverlee oliverlee force-pushed the I756a8416a82f4a2007c7f2461de04353aac667d6 branch from bc35ef4 to c2cd62a Compare October 21, 2023 08:15
@oliverlee
Copy link
Collaborator Author

I think this is the wrong approach and I'll update with a different design later.

@garymm
Copy link
Owner

garymm commented Nov 22, 2023

Do you want me to review? If not mark as draft please

@oliverlee
Copy link
Collaborator Author

Do you want me to review? If not mark as draft please

nope don't review, i'm going to change this at some point

@oliverlee oliverlee marked this pull request as draft January 6, 2024 18:10
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.

2 participants