Get rid of compiler warnings (paying technical debt)
- Dominant language
- C++
- Stars
- 16.7k
- Forks
- 1.6k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 126
Description
Under Linux+OS X we don't have any compilation warnings. But the reason for that is simply because I chose the compilation flags in a way that suppresses these warnings. However, some of these warnings would be very useful. This can be seen on Windows: compilation there generates thousands of warnings.
Not having these useful warnings enabled is bothering me: every bug the compiler can find is a bug I don't have to track down in a simulation run.
The obvious problem with enabling more warnings is, that they will just be ignored as it will be too overwhelming seeing so many of those. I would suggest the following strategy:
1. We should come up with a number of warnings we want to enable in gcc/clang/vsc
1. Each Apple/Snowflake developer takes one or two of these flags, enables it on their fork and fixes all occurrences. I would not be surprised, if this would unearth a few bugs.
1. Enable all these warnings by default and compile with `-Werror`
1. Celebrate the fact that we will have a cleaner code-base and that the compiler will find more bugs for us.
Contributor guide
Research direction
Start by reviewing the compiler flags used for Linux, OS X, and Windows, then identify warning categories that should be enabled and the resulting occurrences. Done means the selected warnings are enabled by default, existing occurrences are fixed, and compilation uses -Werror without overwhelming warning output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- build-system
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100