mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-02-21 02:40:56 +00:00
Added splint.sh (a progressive way to fix some possible bugs)
This commit is contained in:
parent
f1fa8f6055
commit
f58b4a6cd9
2 changed files with 77 additions and 1 deletions
2
ir.h
2
ir.h
|
@ -22,7 +22,7 @@
|
|||
*/
|
||||
#ifndef GMQCC_IR_HDR
|
||||
#define GMQCC_IR_HDR
|
||||
|
||||
#include "gmqcc.h"
|
||||
/* ir_value */
|
||||
|
||||
typedef struct
|
||||
|
|
76
splint.sh
Executable file
76
splint.sh
Executable file
|
@ -0,0 +1,76 @@
|
|||
#!/bin/sh
|
||||
|
||||
#these are stupid flags ... i.e to inhibit warnings that are just stupid
|
||||
FLAGS_STUPID="\
|
||||
-redef \
|
||||
-noeffect \
|
||||
-nullderef \
|
||||
-usedef \
|
||||
-type \
|
||||
-mustfreeonly \
|
||||
-nullstate \
|
||||
-varuse \
|
||||
-mustfreefresh \
|
||||
-compdestroy \
|
||||
-compmempass \
|
||||
-nullpass \
|
||||
-onlytrans \
|
||||
-predboolint \
|
||||
-boolops \
|
||||
-exportlocal \
|
||||
-retvalint \
|
||||
-nullret \
|
||||
-predboolothers \
|
||||
-globstate \
|
||||
-dependenttrans \
|
||||
-branchstate \
|
||||
-compdef \
|
||||
-temptrans \
|
||||
-usereleased \
|
||||
-warnposix"
|
||||
|
||||
#flags that have no place anywhere else
|
||||
#mostly stupid
|
||||
FLAGS_OTHERS="\
|
||||
-shiftimplementation \
|
||||
+charindex \
|
||||
-kepttrans \
|
||||
-unqualifiedtrans \
|
||||
+matchanyintegral \
|
||||
-bufferoverflowhigh \
|
||||
+voidabstract"
|
||||
|
||||
#these are flags that MAYBE shouldn't be required
|
||||
# -nullassign should be surpressed in code with /*@null*/
|
||||
# (although that might be odd?)
|
||||
FLAGS_MAYBE="\
|
||||
-nullassign \
|
||||
-unrecog \
|
||||
-casebreak \
|
||||
-retvalbool \
|
||||
-retvalother \
|
||||
-mayaliasunique \
|
||||
-realcompare \
|
||||
-observertrans \
|
||||
-noret \
|
||||
-shiftnegative \
|
||||
-exitarg \
|
||||
-freshtrans \
|
||||
-abstract \
|
||||
-statictrans"
|
||||
|
||||
#these are flags that shouldn't be required. I.e tofix in code so that
|
||||
#these don't need to be here to onhibit the warning
|
||||
# remove one flag from here at a time while fixing the code so that
|
||||
FLAGS_TOFIX="\
|
||||
-boolcompare \
|
||||
-formatconst \
|
||||
-unreachable \
|
||||
-incondefs \
|
||||
-initallelements \
|
||||
-macroredef \
|
||||
-castfcnptr \
|
||||
-evalorder"
|
||||
|
||||
|
||||
splint $FLAGS_STUPID $FLAGS_MAYBE $FLAGS_TOFIX $FLAGS_OTHERS *.c *.h
|
Loading…
Reference in a new issue