cppalliance / http_proto

HTTP/1 parsing and serialization algorithms using C++11
https://develop.http-proto.cpp.al/
Boost Software License 1.0
23 stars 10 forks source link

stream prepare has nullary overload #81

Closed cmazakas closed 6 months ago

vinniefalco commented 7 months ago

Well shouldn't we remove the 1-arg overload?

codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 89.37%. Comparing base (b5cbccc) to head (b2b46e8).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/cppalliance/http_proto/pull/81/graphs/tree.svg?width=650&height=150&src=pr&token=IoZbqjUnBr&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance)](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance) ```diff @@ Coverage Diff @@ ## develop #81 +/- ## =========================================== + Coverage 89.23% 89.37% +0.13% =========================================== Files 77 77 Lines 4339 4348 +9 =========================================== + Hits 3872 3886 +14 + Misses 467 462 -5 ``` | [Files](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance) | Coverage Δ | | |---|---|---| | [include/boost/http\_proto/serializer.hpp](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?src=pr&el=tree&filepath=include%2Fboost%2Fhttp_proto%2Fserializer.hpp&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance#diff-aW5jbHVkZS9ib29zdC9odHRwX3Byb3RvL3NlcmlhbGl6ZXIuaHBw) | `97.43% <ø> (ø)` | | | [src/serializer.cpp](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?src=pr&el=tree&filepath=src%2Fserializer.cpp&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance#diff-c3JjL3NlcmlhbGl6ZXIuY3Bw) | `92.03% <100.00%> (+2.27%)` | :arrow_up: | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/cppalliance/http_proto/pull/81/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance). Last update [b5cbccc...b2b46e8](https://app.codecov.io/gh/cppalliance/http_proto/pull/81?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=cppalliance).
cppalliance-bot commented 7 months ago

GCOVR code coverage report https://81.http-proto.prtest.cppalliance.org/gcovr/index.html
LCOV code coverage report https://81.http-proto.prtest.cppalliance.org/genhtml/index.html Coverage Diff https://81.http-proto.prtest.cppalliance.org/gcovr/coverage_diff.txt

cmazakas commented 7 months ago

Well shouldn't we remove the 1-arg overload?

Good question. I didn't see a reason to outright remove it.

I suppose users can take the return from stream::preapre() and then use Buffers to manipulate it. If you want, I can go ahead and remove the stream::preapre(std::size_t); overload

cppalliance-bot commented 7 months ago

GCOVR code coverage report https://81.http-proto.prtest.cppalliance.org/gcovr/index.html
LCOV code coverage report https://81.http-proto.prtest.cppalliance.org/genhtml/index.html Coverage Diff https://81.http-proto.prtest.cppalliance.org/gcovr/coverage_diff.txt

cppalliance-bot commented 7 months ago

GCOVR code coverage report https://81.http-proto.prtest.cppalliance.org/gcovr/index.html
LCOV code coverage report https://81.http-proto.prtest.cppalliance.org/genhtml/index.html Coverage Diff https://81.http-proto.prtest.cppalliance.org/gcovr/coverage_diff.txt

cppalliance-bot commented 7 months ago

GCOVR code coverage report https://81.http-proto.prtest.cppalliance.org/gcovr/index.html
LCOV code coverage report https://81.http-proto.prtest.cppalliance.org/genhtml/index.html Coverage Diff https://81.http-proto.prtest.cppalliance.org/gcovr/coverage_diff.txt

cppalliance-bot commented 6 months ago

GCOVR code coverage report https://81.http-proto.prtest.cppalliance.org/gcovr/index.html
LCOV code coverage report https://81.http-proto.prtest.cppalliance.org/genhtml/index.html Coverage Diff https://81.http-proto.prtest.cppalliance.org/gcovr/coverage_diff.txt