4 ms·
> This is not a reason to avoid -Werror Sorry but it really was. Passing Werror like confetti was the root cause of a problem that led to two weeks of downtime
by nuerow 5y ago
> This is not a reason to avoid -Werror
Sorry but it really was. Passing Werror like confetti was the root cause of a problem that led to two weeks of downtime and added absolutely no value at all, and the solution consisted of addressing said warnings alone. And if there was any doubt, the upgrade was undoubtedly trivial, mainly due to the fact that the project still targeted C++11, and with exception of the Werror nonsense was absolutely flawless.
- MaulingMonkey 5y ago> and the solution consisted of addressing said warnings alone. Alternative solutions which should not have taken two weeks would've included: -Wno-inane-drivel-involving-white-spaces -Wno-error=inane-drivel-involving-white-spaces Just because you're using -Werror doesn't mean literally every single warning in the compiler ever should be a hard error. It means errors should be the default, allowing you to opt-out of stupid warnings-as-errors, rather than needing to opt-in to critical warnings-as-errors.
- Arnavion 5y agoIf the team that owned these dependencies were militant enough to enable Werror for tests, they might have also insisted that the warnings be fixed properly instead of being suppressed.
- dv_dt 5y agoI have had instances where upgrades of the compiler added bugs, or where warnings identified new potential bugs. And not always revolving around the error flags either. The update after analysis and probably some retesting concluded as trivial, but before undertaking the change I think it has a risk of having the same impact as a change of software. It’s not -Werror at the root of this general work (yes it turned that way in this specific case), but the analysis and recheck after was the core work from the compiler upgrade.