Add more warnings to develop

As suggested by #969
This commit is contained in:
ISSOtm
2022-02-05 13:24:32 +01:00
committed by Eldred Habert
parent a48801a675
commit b3304ae1ac
2 changed files with 6 additions and 4 deletions

View File

@@ -46,11 +46,12 @@ else()
if(MORE_WARNINGS)
add_compile_options(-Werror -Wextra
-Walloc-zero -Wcast-align -Wcast-qual -Wduplicated-cond
-Walloc-zero -Wcast-align -Wcast-qual -Wduplicated-branches -Wduplicated-cond
-Wfloat-equal -Winline -Wlogical-op -Wnested-externs -Wold-style-definition
-Wshift-overflow=2
-Wstrict-overflow=5 -Wstrict-prototypes -Wundef -Wuninitialized -Wunused
-Wshadow # TODO: -Wshadow=compatible-local ?
-Wstringop-overflow=4 # TODO: would work better with optimizations
-Wnull-dereference -Wstringop-overflow=4 # TODO: would work better with optimizations
-Wno-sign-compare # TODO: fix those warnings
-Wformat=2 -Wformat-overflow=2 -Wformat-truncation=1
-Wno-format-nonliteral # We have a couple of "dynamic" prints

View File

@@ -213,11 +213,12 @@ checkdiff:
develop:
$Qenv ${MAKE} WARNFLAGS="-Werror -Wextra \
-Walloc-zero -Wcast-align -Wcast-qual -Wduplicated-cond \
-Walloc-zero -Wcast-align -Wcast-qual -Wduplicated-branches -Wduplicated-cond \
-Wfloat-equal -Winline -Wlogical-op -Wnested-externs -Wold-style-definition \
-Wshift-overflow=2 \
-Wstrict-overflow=5 -Wstrict-prototypes -Wundef -Wuninitialized -Wunused \
-Wshadow \
-Wstringop-overflow=4 \
-Wnull-dereference -Wstringop-overflow=4 \
-Wno-sign-compare \
-Wformat=2 -Wformat-overflow=2 -Wformat-truncation=1 \
-Wno-format-nonliteral \