[Rpm-maint] [rpm-software-management/rpm] Get rid of -Wno-sign-compare (Issue #3226)

Panu Matilainen notifications at github.com
Mon Jan 13 11:06:18 UTC 2025


Hmm, I didn't remember thinking of this as potential 6.0 material, but then that's half a year ago. As said in the PR, I don't think we should do this kind of risky mass-changes this late in the cycle. What's missing in the description of the ticket is that such a change needs a planned strategy first, "it compiles" is not enough.

When looking to eliminate the warnings:
- Eliminate the manual type from the picture entirely where possible (eg, use iterators in loops instead, auto/decltype etc). std::span will help with that so this might be one of those things where we want to wait until c++20 for any mass-changes on this front.
- Fix the root cause rather than just cast it away 
- For the handful of cases that simply have to be cast, use C++ casts
- When multiple places need the same cast, look to add a helper function where you can handle the cast in a one central spot

Submitting fixes to individual bits and pieces in well-tested areas one or two at a time is okay, but not en-masse.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/3226#issuecomment-2586806063
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/issues/3226/2586806063 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20250113/2c279760/attachment-0001.htm>


More information about the Rpm-maint mailing list