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
refactor: modernize cache.cc #3108
Conversation
@kvakvs I removed it because I was going to use https://github.com/martinmoene/span-lite or https://github.com/microsoft/GSL ot https://github.com/gsl-lite/gsl-lite instead, but then I kept looping on which to use (mostly deciding between most-lightweight span-lite or best-maintained GSL) and never did anything. If this is a blocker for this PR I'll take a look again. There are several places in libtransmission that would be improved by using a span. |
For the moment it is not a blocker at all. |
A few cache tests fail without actually crashing. |
@kvakvs I'll try to take a look in the next couple of days. Sorry for the delay; a lot of my time this week has been taken up afk. Also, FWIW needing help with this code is totally understandable. I kind of hate this code and I'm the one who wrote it 🤷♂️ |
tr_cache
to a classsize_t
where appropriateblocks
with C++.clang-format-ignore
and.gitignore